Giter VIP home page Giter VIP logo

azure / azure-cli-extensions Goto Github PK

View Code? Open in Web Editor NEW
367.0 159.0 1.1K 452.44 MB

Public Repository for Extensions of Azure CLI.

Home Page: https://docs.microsoft.com/en-us/cli/azure

License: MIT License

Python 99.90% Shell 0.02% Batchfile 0.01% PowerShell 0.01% ANTLR 0.01% Q# 0.01% Open Policy Agent 0.02% JavaScript 0.01% CSS 0.01% EJS 0.01% HTML 0.01% C# 0.01% Dockerfile 0.01% Jinja 0.01% Bicep 0.02% Smarty 0.01% Mustache 0.01% VHDL 0.01%
azure-cli azure-cli-extension

azure-cli-extensions's Introduction

Extensions for Azure CLI 2.0

This repository serves two purposes and they are independent:

  1. A source code directory, src, to host your extension source code.
  2. An index.json where you can add your extension and make it available through Azure CLI.

For documentation on authoring an extension, see Extension Documentation

About index.json

  • The index is at src/index.json.
  • Modify the index by creating a PR.
  • All extensions added to the index are public and will be available to all CLI users.
  • The index is synced to https://aka.ms/azure-cli-extension-index-v1 every few minutes.
  • Your extension source code does not have to be in this repository to be available in the index.
  • If you don't want your extension to be part of the index, you can still host it externally and request users to install with az extension add --source https://contoso.com/mywheel.whl.
    • Users will not be able to add your extension by name, it will not be listed in the az extension list-available command and to update to a new version of your extension, the user has to first remove the currently installed extension and then add the new version.

Add your extension to the index to make it available in these CLI commands:

  • az extension add --name NAME - Allows users to add an extension by name
  • az extension list-available - Allows users to list the available extensions in the index
  • az extension update --name NAME - Allows users to update an extension

About source code in this repository

  • Extension source code goes into the src directory.
  • You can place your source code in this repository by creating a PR.
  • Once CI is green and it has been approved, the PR can be merged.
  • SDKs generated from AutoRest often do not pass CI static-checking. If they are vendored inside the extension, exclude them from static checking by placing them in the folder: src/<extension root>/azext_*/vendored_sdks.
  • Ensure that you include an appropriate owner for your extension in .github/CODEOWNERS.
  • Your extension artifact (i.e. .whl) will not live in this repository. You can publish your extension to PyPI or somewhere else such as Azure Storage.
  • If you want your extension to appear in the index.json, modify the index.

About extension publishing

There is a pipeline to automatically build, upload and publish extension wheels.

Once your PR is merged into master branch, a new PR will be created to update src/index.json automatically.

The precondition is to put your code inside this repo and upgrade the version in the PR but not to modify src/index.json.

If you want to host the source code in your dedicated repo, you have to upload the WHL file and update the src/index.json manually.

For detail, please visit Publish section in Azure CLI Extension Authoring.

FAQ

How to generate sha256digest for an index.json entry?

If you use azdev extension update-index the command will calculate the SHA256 digest for you. For more information visit https://github.com/Azure/azure-cli-dev-tools.

As a fallback:

MacOS

shasum -a 256 path_to_whl.whl

Windows / PowerShell

Get-FileHash path_to_whl.whl -Algorithm SHA256

Note: Hash should be in lowercase in index.json otherwise CI will fail.

How to fill in the metadata for an index.json entry?

The azdev extension update-index command can be used to simplify the process of updating the index file. Run azdev extension update-index <URL> where URL is the fully-qualified URL to your published extension WHL. This will gather the appropriate metadata and add an entry for your extension to the index. For more information visit https://github.com/Azure/azure-cli-dev-tools.

As a fallback:

The metadata needed to be filled is a combination of the contents present in:

  • metadata.json located in your unzipped extension artifact (.whl file) in the <package>-<version>.dist-info directory. This metadata is garnered from the setup.py folder.
  • azext_metadata.json (if it exists) under your extension.

Note that CI will fail if this metadata does not match the contents of your published extension.

Contributing

This project welcomes contributions and suggestions. Most contributions require you to agree to a Contributor License Agreement (CLA) declaring that you have the right to, and actually do, grant us the rights to use your contribution. For details, visit https://cla.microsoft.com.

When you submit a pull request, a CLA-bot will automatically determine whether you need to provide a CLA and decorate the PR appropriately (e.g., label, comment). Simply follow the instructions provided by the bot. You will only need to do this once across all repos using our CLA.

This project has adopted the Microsoft Open Source Code of Conduct. For more information see the Code of Conduct FAQ or contact [email protected] with any additional questions or comments.

azure-cli-extensions's People

Contributors

allyw avatar azclibot avatar c-ryan-k avatar derekbekoe avatar digimaun avatar evelyn-ys avatar fengzhou-msft avatar fumingzhang avatar greedygre avatar haroldrandom avatar j-so avatar jiec-msft avatar jing-song avatar jonathan-innis avatar jsntcy avatar juliehzl avatar kairu-ms avatar limingu avatar mmyyrroonn avatar ricardo-espinoza avatar strawnsc avatar swells avatar wangzelin007 avatar warren-jones avatar williexu avatar xfz11 avatar yugangw-msft avatar yuwzho avatar zengtaoxu avatar zhoxing-ms avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

azure-cli-extensions's Issues

Can't use az image copy

image-copy-extension

'NoneType' object is not subscriptable

Getting os disk id of the source vm/image
'NoneType' object is not subscriptable
Traceback (most recent call last):
File "/opt/az/lib/python3.6/site-packages/knack/cli.py", line 194, in invoke
cmd_result = self.invocation.execute(args)
File "/opt/az/lib/python3.6/site-packages/azure/cli/core/commands/init.py", line 342, in execute
six.reraise(*sys.exc_info())
File "/opt/az/lib/python3.6/site-packages/six.py", line 693, in reraise
raise value
File "/opt/az/lib/python3.6/site-packages/azure/cli/core/commands/init.py", line 315, in execute
result = cmd(params)
File "/opt/az/lib/python3.6/site-packages/azure/cli/core/commands/init.py", line 175, in call
return super(AzCliCommand, self).call(*args, **kwargs)
File "/opt/az/lib/python3.6/site-packages/knack/commands.py", line 109, in call
return self.handler(*args, **kwargs)
File "/opt/az/lib/python3.6/site-packages/azure/cli/core/init.py", line 349, in default_command_handler
result = op(**command_args)
File "/home/Wolfthorne/.azure/cliextensions/image-copy-extension/azext_imagecopy/custom.py", line 27, in imagecopy
source_os_disk_id = json_cmd_output['storageProfile']['osDisk']['managedDisk']['id']
TypeError: 'NoneType' object is not subscriptable

Azure interactive: save JSON output to a file.

Is there a way from the azure interactive window to save the command JSON output redirect to a file?
ie.
az>> account list --all
returns JSON output, I want to redirect the output to a file.


Environment summary

Install Method (e.g. pip, interactive script, apt-get, Docker, MSI, edge build) / CLI version (az --version) / OS version / Shell Type (e.g. bash, cmd.exe, Bash on Windows)

Add support for VB and F# projects in az webapp up

Extension name (the extension in question)

webapp

Description of issue (in as much detail as possible)

az webapp new currently only looks for *.csproj to determine if it's a .NET project. It should also look for *.vbproj and *.fsproj.

Interactive mode 'progress' causes visual corruption when output errors

Description

When errors happen with --progress set, errors cause the output to become corrupted.


az>> az vm create -g MyRG -n MyVM --image UbuntuLTS --progress
az>> Exception in thread Thread-120:
Traceback (most recent call last):
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/threading.py", line 810, in __bootstrap_inn
    self.run()
  File "/Users/jasonsha/lib/azure-cli/lib/python2.7/site-packages/azclishell/app.py", line 736, in run
    self.func(self.args)
  File "/Users/jasonsha/lib/azure-cli/lib/python2.7/site-packages/azure/cli/core/application.py", line 211, in execute
    result = expanded_arg.func(params)
  File "/Users/jasonsha/lib/azure-cli/lib/python2.7/site-packages/azure/cli/core/commands/__init__.py", line 346, in __cal
    return self.handler(*args, **kwargs)                     *--image:
  File "/Users/jasonsha/lib/azure-cli/lib/python2.7/site-packages/azure/cli/core/commands/__init__.py", line 542, in _exec
    exception_handler(ex)                                    *URN, Custom Image name or ID, or VHD Blob URI). 
  File "/Users/jasonsha/lib/azure-cli/lib/python2.7/site-packages/azure/cli/core/commands/arm.py", line 66, in handle_long
    raise cli_error                                          *be replaced by others (for example, `--attach-os-disk`).
CLIError: Deployment failed. {                               *
  "error": {--------------------------------------------------------------------------------------------------------------
    "code": "Conflict",ntu VM with automatic SSH authentication.
    "message": "The request failed due to conflict with a concurrent request. "
  }
}2] Create a simple Windows Server VM with a private IP address.
az vm create -n MyVm -g MyResourceGroup
az>> 

Bug: az webapp new stopped working for Node.js projects

Extension name (the extension in question)

webapp

Description of issue (in as much detail as possible)

Looks like the new support for .NET may have caused Node.js projects to no longer work. Repro:

bash-4.3# git clone https://github.com/scotch-io/node-todo.git
Cloning into 'node-todo'...
remote: Counting objects: 464, done.
remote: Total 464 (delta 0), reused 0 (delta 0), pack-reused 464
Receiving objects: 100% (464/464), 61.07 KiB | 0 bytes/s, done.
Resolving deltas: 100% (163/163), done.
Checking connectivity... done.
bash-4.3# cd node-todo/
bash-4.3# ls
README.md     README_es.md  app           config        license       package.json  public        server.js
bash-4.3# az webapp new -n test-node-todo
list index out of range
Traceback (most recent call last):
  File "/usr/local/lib/python3.6/site-packages/knack/cli.py", line 194, in invoke
    cmd_result = self.invocation.execute(args)
  File "/usr/local/lib/python3.6/site-packages/azure/cli/core/commands/__init__.py", line 331, in execute
    six.reraise(*sys.exc_info())
  File "/usr/local/lib/python3.6/site-packages/six.py", line 693, in reraise
    raise value
  File "/usr/local/lib/python3.6/site-packages/azure/cli/core/commands/__init__.py", line 304, in execute
    result = cmd(params)
  File "/usr/local/lib/python3.6/site-packages/azure/cli/core/commands/__init__.py", line 168, in __call__
    return super(AzCliCommand, self).__call__(*args, **kwargs)
  File "/usr/local/lib/python3.6/site-packages/knack/commands.py", line 109, in __call__
    return self.handler(*args, **kwargs)
  File "/usr/local/lib/python3.6/site-packages/azure/cli/core/__init__.py", line 348, in default_command_handler
    result = op(**command_args)
  File "/root/.azure/cliextensions/webapp/azext_webapp/custom.py", line 50, in create_deploy_webapp
    lang_details = get_lang_from_content(src_dir)
  File "/root/.azure/cliextensions/webapp/azext_webapp/create_util.py", line 113, in get_lang_from_content
    package_netcore_file = os.path.join(src_path, glob.glob("*.csproj")[0])
IndexError: list index out of range
bash-4.3# 

@ahmedelnably @panchagnula

[Interactive] Allow referencing different scope while staying in current scope


Currently, one has to actively change scope to run a different command
-similar to using a ls ~ or ls .. on shell while in current scope.

Environment summary

Install Method (e.g. pip, interactive script, apt-get, Docker, MSI, edge build) / CLI version (az --version) / OS version / Shell Type (e.g. bash, cmd.exe, Bash on Windows)

Interactive and progress reporting omnibus

Here is a list of features

  • Turn on progress reporting for a running command (you hit enter 2 minutes ago, is it still going?)
  • Show elapsed time on the heartbeat
  • heartbeat should show number of operations running (if i start 4 vms with --progress, how many are left)
  • In --verbose mode, output start and total time of the deployment
  • Remove layout from F1 spot, and put Keys there instead, and call it help
  • fix all the reflow issues (jpterm handles this WAY better)
  • fix all the output errors (F3 makes the status bar move back and forth)
  • add examples to az interactive -h
  • we should cache outputs of --progress tasks and provide a progress history they can look at (create a vm with --progress, but get the IP address when it is done)
  • add a message carasol to the bottom where the heartbeat goes.

Certain interactive commands complete with 'NoneType' object has no attribute 'init_progress'

Install Method: apt-get

CLI Version:

azure-cli (2.0.24)

acr (2.0.18)
acs (2.0.23)
advisor (0.1.1)
appservice (0.1.23)
backup (1.0.4)
batch (3.1.8)
batchai (0.1.4)
billing (0.1.7)
cdn (0.0.11)
cloud (2.0.11)
cognitiveservices (0.1.10)
command-modules-nspkg (2.0.1)
configure (2.0.13)
consumption (0.2.1)
container (0.1.16)
core (2.0.24)
cosmosdb (0.1.16)
dla (0.0.16)
dls (0.0.19)
eventgrid (0.1.7)
extension (0.0.7)
feedback (2.0.7)
find (0.2.8)
interactive (0.3.12)
iot (0.1.16)
keyvault (2.0.16)
lab (0.0.14)
monitor (0.0.14)
network (2.0.20)
nspkg (3.0.1)
profile (2.0.17)
rdbms (0.0.10)
redis (0.2.11)
reservations (0.1.1)
resource (2.0.20)
role (2.0.16)
servicefabric (0.0.8)
sql (2.0.18)
storage (2.0.22)
vm (2.0.23)

Python location '/opt/az/bin/python3'
Extensions directory '/home/tda/.azure/cliextensions'

Python (Linux) 3.6.1 (default, Jan  5 2018, 21:18:08)
[GCC 4.8.4]

OS Version:

Distributor ID: Ubuntu
Description:    Ubuntu 16.04.3 LTS
Release:        16.04
Codename:       xenial

Shell: bash

Issue:

  1. az interactive. Output:
az>> Command: provider list not in Command Table
Command: sql db op cancel not in Command Table
Command: storage account generate-sas not in Command Table
  1. Hit enter and create a new group:

az>> group create -n test -l westeurope -o json

  1. Try and delete the group:
az>> group delete -n test -y
'NoneType' object has no attribute 'init_progress'
Traceback (most recent call last):
  File "/opt/az/lib/python3.6/site-packages/knack/cli.py", line 193, in invoke
    cmd_result = self.invocation.execute(args)
  File "/opt/az/lib/python3.6/site-packages/azure/cli/core/commands/__init__.py", line 319, in execute
    six.reraise(*sys.exc_info())
  File "/opt/az/lib/python3.6/site-packages/six.py", line 693, in reraise
    raise value
  File "/opt/az/lib/python3.6/site-packages/azure/cli/core/commands/__init__.py", line 303, in execute
    result = LongRunningOperation(self.cli_ctx, 'Starting {}'.format(cmd.name))(result)
  File "/opt/az/lib/python3.6/site-packages/azure/cli/core/commands/__init__.py", line 438, in __call__
    self.cli_ctx.get_progress_controller().begin()
  File "/opt/az/lib/python3.6/site-packages/azclishell/app.py", line 679, in progress_patch
    self.cli_ctx.progress_controller.init_progress(ShellProgressView())
AttributeError: 'NoneType' object has no attribute 'init_progress'
'int' object has no attribute 'result'
Traceback (most recent call last):
  File "/opt/az/lib/python3.6/site-packages/azclishell/app.py", line 660, in cli_execute
    if result and result.result is not None:
AttributeError: 'int' object has no attribute 'result'
az>>

Additional Information:

The group is deleted but the it exits immediately without waiting for the completion (without --no-wait)
The intellisence / autocompletion does not seem to work either

Use `az webapp up` (no flags) to redeploy

Extension name (the extension in question)

webapp

Description of issue (in as much detail as possible)

Currently, the user needs to specify the name (az webapp new -n <name>) to redeploy a folder. It would be great if the original deployment settings can be saved in a config file locally so that the user can simply run az webapp new to redeploy.

2 advantages:

  • easier redeployment
  • less error prone (won't accidentally run the command in the wrong folder an wipe out an existing app)

Interactive mode mode app directory should be moved

After using az interactive users find they now have a ~/.azure-shell directory, which is confusing to Azure Cloud Shell users who expect this directory to relate to the cloud-shell feature in portal.

$ ls -A
.azure  .bash_history  .bash_logout  .bashrc  .cache  clouddrive  .profile  temp.azcli
$ az interactive
$ la -A   
.azure  .azure-shell  .bash_history  .bash_logout  .bashrc  .cache  clouddrive  .config  .profile  temp.azcli

az webapp new throws an exception when it can't detect a project type.

Extension name (the extension in question)

webapp

Description of issue (in as much detail as possible)

This should fail gracefully:

bash-4.3# cd /
bash-4.3# ls
appp       bin        etc        lib        media      proc       run        srv        tmp        var
azure-cli  dev        home       linuxrc    mnt        root       sbin       sys        usr
bash-4.3# az webapp new -n foo
list index out of range
Traceback (most recent call last):
  File "/usr/local/lib/python3.6/site-packages/knack/cli.py", line 194, in invoke
    cmd_result = self.invocation.execute(args)
  File "/usr/local/lib/python3.6/site-packages/azure/cli/core/commands/__init__.py", line 331, in execute
    six.reraise(*sys.exc_info())
  File "/usr/local/lib/python3.6/site-packages/six.py", line 693, in reraise
    raise value
  File "/usr/local/lib/python3.6/site-packages/azure/cli/core/commands/__init__.py", line 304, in execute
    result = cmd(params)
  File "/usr/local/lib/python3.6/site-packages/azure/cli/core/commands/__init__.py", line 168, in __call__
    return super(AzCliCommand, self).__call__(*args, **kwargs)
  File "/usr/local/lib/python3.6/site-packages/knack/commands.py", line 109, in __call__
    return self.handler(*args, **kwargs)
  File "/usr/local/lib/python3.6/site-packages/azure/cli/core/__init__.py", line 348, in default_command_handler
    result = op(**command_args)
  File "/root/.azure/cliextensions/webapp/azext_webapp/custom.py", line 50, in create_deploy_webapp
    lang_details = get_lang_from_content(src_dir)
  File "/root/.azure/cliextensions/webapp/azext_webapp/create_util.py", line 113, in get_lang_from_content
    package_netcore_file = os.path.join(src_path, glob.glob("*.csproj")[0])
IndexError: list index out of range
bash-4.3# 

Steps to reproduce: run az webapp new -n foo in a non-empty directory that does not contain a package.json or a *.csproj file.

Interactive mode should display help when a group is entered

Using interactive mode should feel fluid, but when exploring the command structure for a service, I don't find the terse nature of the argument exception usage being helpful.

Currently

$ az interactive
az>> monitor
az monitor: error: the following arguments are required: subcommand
usage: az monitor [-h]
                  {alert,metrics,log-profiles,diagnostic-settings,autoscale-settings,activity-log}
                  ...

Desired

az>> monitor
interactive-mode showing help:
    az monitor: Commands to manage Azure Monitor service.

Subgroups:
    activity-log       : Commands to manage activity log.
    alert              : Commands to manage metric-based alert rules.
    autoscale-settings : Commands to manage autoscale settings.
    diagnostic-settings: Commands to manage service diagnostic settings.
    log-profiles       : Commands to manage the log profiles assigned to Azure subscription.
    metrics            : Commands to view Azure resource metrics.

Better testing for Interactive mode


Seems like things break a lot in interactive and we don't realize it until people try it. Interactive needs unique, thorough test, that test the flow of information and function calls, not just tests for specific function calls.

Things to test more thoroughly:

  • gathering commands from help dump
  • writing command table information into help dump
  • success in instantiating a completer, and its validity in processing command
  • use of --progress
  • scoping and ability to run correct commands in different scopes
  • success in storing/reading from history

This is not an exhaustive list and will be ongoing work

Environment summary

Install Method (e.g. pip, interactive script, apt-get, Docker, MSI, edge build) / CLI version (az --version) / OS version / Shell Type (e.g. bash, cmd.exe, Bash on Windows)

image-copy should hash location and subscription for storage account name

Extension name (the extension in question)

image-copy

Description of issue (in as much detail as possible)

https://github.com/Azure/azure-cli-extensions/blob/master/src/image-copy/azext_imagecopy/create_target.py#L32

  • australiasoutheast + subscription_hash[:7] is longer as the limit for storage accounts

dirty work around in the create-target.py

    subscription_hash = hashlib.sha1(subscription_id.encode("UTF-8")).hexdigest()
    location_hash = hashlib.sha1(location.encode("UTF-8")).hexdigest()
    unique_storage_account_string = location_hash[:11] + subscription_hash[:11]

    # create the target storage account
    logger.warn(
        "%s - %s - Creating target storage account (can be slow sometimes)", location, unique_storage_account_string)
    target_storage_account_name = unique_storage_account_string

should be uniqe enough, while still under the limit of 24 chars

Lazy loading of command table data in interactive.


-this will allow the completers, which rely on the command_table, to kick in right from the get-go.
-parameter completers will not have to wait for full command table dump.

Environment summary

Install Method (e.g. pip, interactive script, apt-get, Docker, MSI, edge build) / CLI version (az --version) / OS version / Shell Type (e.g. bash, cmd.exe, Bash on Windows)

Extension add fails due to "libffi.so.5: cannot open shared object file: No such file or directory"

Extension name (the extension in question)

webapp

Description of issue (in as much detail as possible)

Running az extension add --name webapp results in an error. "An error occurred. Pip failed with status code 1. Use --debug for more information." When run with --debug the problem seems to be related to importing libffi.so.5.
I am running WSL on Windows 10 (1709) with latest version of CLI (2.0.27)

Full output of command with --debug (click to expand)

$ az extension add --name webapp --debug
Command arguments: ['extension', 'add', '--name', 'webapp', '--debug']
Event: Cli.PreExecute []
Event: CommandParser.OnGlobalArgumentsCreate [<function CLILogging.on_global_arguments at 0x7f56a70142f0>, <function OutputProducer.on_global_arguments at 0x7f56a6b21ea0>, <function CLIQuery.on_global_arguments at 0x7f56a66b09d8>]
Event: CommandInvoker.OnPreCommandTableCreate [<function CLILogging.remove_logger_flags at 0x7f56a7014378>]
Installed command modules ['acr', 'acs', 'advisor', 'appservice', 'backup', 'batch', 'batchai', 'billing', 'cdn', 'cloud', 'cognitiveservices', 'configure', 'consumption', 'container', 'cosmosdb', 'dla', 'dls', 'eventgrid', 'extension', 'feedback', 'find', 'interactive', 'iot', 'keyvault', 'lab', 'monitor', 'network', 'profile', 'rdbms', 'redis', 'reservations', 'resource', 'role', 'servicefabric', 'sql', 'storage', 'vm']
Loaded module 'acr' in 0.016 seconds.
Loaded module 'acs' in 0.012 seconds.
Loaded module 'advisor' in 0.011 seconds.
Loaded module 'appservice' in 0.016 seconds.
Loaded module 'backup' in 0.011 seconds.
Event: CommandLoader.OnLoadCommandTable []
Loaded module 'batch' in 0.031 seconds.
Loaded module 'batchai' in 0.012 seconds.
Loaded module 'billing' in 0.011 seconds.
Event: CommandLoader.OnLoadCommandTable []
Loaded module 'cdn' in 0.013 seconds.
Loaded module 'cloud' in 0.012 seconds.
Loaded module 'cognitiveservices' in 0.009 seconds.
Loaded module 'configure' in 0.007 seconds.
Loaded module 'consumption' in 0.018 seconds.
Loaded module 'container' in 0.012 seconds.
Loaded module 'cosmosdb' in 0.015 seconds.
Loaded module 'dla' in 0.015 seconds.
Loaded module 'dls' in 0.011 seconds.
Loaded module 'eventgrid' in 0.012 seconds.
Loaded module 'extension' in 0.006 seconds.
Loaded module 'feedback' in 0.007 seconds.
Loaded module 'find' in 0.008 seconds.
Loaded module 'interactive' in 0.002 seconds.
Loaded module 'iot' in 0.015 seconds.
Loaded module 'keyvault' in 0.018 seconds.
Loaded module 'lab' in 0.017 seconds.
Loaded module 'monitor' in 0.020 seconds.
Loaded module 'network' in 0.037 seconds.
Loaded module 'profile' in 0.013 seconds.
Loaded module 'rdbms' in 0.014 seconds.
Loaded module 'redis' in 0.012 seconds.
Loaded module 'reservations' in 0.013 seconds.
Loaded module 'resource' in 0.015 seconds.
Loaded module 'role' in 0.012 seconds.
Loaded module 'servicefabric' in 0.009 seconds.
Loaded module 'sql' in 0.015 seconds.
Event: CommandLoader.OnLoadCommandTable []
Loaded module 'storage' in 0.044 seconds.
Loaded module 'vm' in 0.025 seconds.
Loaded all modules in 0.544 seconds. (note: there's always an overhead with the first module loaded)
Extensions directory: '/home/ben/.azure/cliextensions'
Event: CommandInvoker.OnPreCommandTableTruncate []
Event: CommandInvoker.OnPostCommandTableCreate [<function add_id_parameters at 0x7f56a48569d8>]
Event: CommandInvoker.OnCommandTableLoaded []
Event: CommandInvoker.OnPreParseArgs [<function _documentdb_deprecate at 0x7f56a4695268>]
Event: CommandInvoker.OnPostParseArgs [<function OutputProducer.handle_output_argument at 0x7f56a6b21f28>, <function CLIQuery.handle_query_parameter at 0x7f56a66b0a60>]
Extensions directory: '/home/ben/.azure/cliextensions'
urllib3.connectionpool : Starting new HTTPS connection (1): aka.ms
urllib3.connectionpool : https://aka.ms:443 "GET /azure-cli-extension-index-v1 HTTP/1.1" 301 186
urllib3.connectionpool : Starting new HTTPS connection (1): azurecliextensionsync.blob.core.windows.net
urllib3.connectionpool : https://azurecliextensionsync.blob.core.windows.net:443 "GET /index1/index.json HTTP/1.1" 200 22317
Candidates ['webapp-0.0.8-py2.py3-none-any.whl']
Candidates ['webapp-0.0.8-py2.py3-none-any.whl']
Candidates ['webapp-0.0.8-py2.py3-none-any.whl']
Candidates ['webapp-0.0.8-py2.py3-none-any.whl']
Choosing the latest of the remaining candidates.
Chosen {'filename': 'webapp-0.0.8-py2.py3-none-any.whl', 'sha256Digest': '4800c51978f7801b613f93afc62367c6646839dc4fd99c7673f4e217ba96cc58', 'downloadUrl': 'https://github.com/panchagnula/azure-cli-extensions/raw/sisirap-extensions-whl/dist/webapp-0.0.8-py2.py3-none-any.whl', 'metadata': {'classifiers': ['Development Status :: 4 - Beta', 'Intended Audience :: Developers', 'Intended Audience :: System Administrators', 'Programming Language :: Python', 'Programming Language :: Python :: 2', 'Programming Language :: Python :: 2.7', 'Programming Language :: Python :: 3', 'Programming Language :: Python :: 3.4', 'Programming Language :: Python :: 3.5', 'Programming Language :: Python :: 3.6', 'License :: OSI Approved :: MIT License'], 'extensions': {'python.details': {'contacts': [{'email': '[email protected]', 'name': 'Sisira Panchagnula', 'role': 'author'}], 'document_names': {'description': 'DESCRIPTION.rst'}, 'project_urls': {'Home': 'https://github.com/Azure/azure-cli-extensions'}}}, 'generator': 'bdist_wheel (0.29.0)', 'license': 'MIT', 'metadata_version': '2.0', 'name': 'webapp', 'summary': 'An Azure CLI Extension to manage appservice resources', 'version': '0.0.8'}}
Extension source is url? True
Extensions directory: '/home/ben/.azure/cliextensions'
Downloading https://github.com/panchagnula/azure-cli-extensions/raw/sisirap-extensions-whl/dist/webapp-0.0.8-py2.py3-none-any.whl to /tmp/tmp4ly546cw/webapp-0.0.8-py2.py3-none-any.whl
urllib3.connectionpool : Starting new HTTPS connection (1): github.com
urllib3.connectionpool : https://github.com:443 "GET /panchagnula/azure-cli-extensions/raw/sisirap-extensions-whl/dist/webapp-0.0.8-py2.py3-none-any.whl HTTP/1.1" 302 194
urllib3.connectionpool : Starting new HTTPS connection (1): raw.githubusercontent.com
urllib3.connectionpool : https://raw.githubusercontent.com:443 "GET /panchagnula/azure-cli-extensions/sisirap-extensions-whl/dist/webapp-0.0.8-py2.py3-none-any.whl HTTP/1.1" 200 8686
Downloaded to /tmp/tmp4ly546cw/webapp-0.0.8-py2.py3-none-any.whl
Validating the extension /tmp/tmp4ly546cw/webapp-0.0.8-py2.py3-none-any.whl
Checksum of /tmp/tmp4ly546cw/webapp-0.0.8-py2.py3-none-any.whl is OK
Extension compatibility result: is_compatible=True cli_core_version=2.0.27 min_required=None max_required=None
Validation successful on /tmp/tmp4ly546cw/webapp-0.0.8-py2.py3-none-any.whl
Executing pip with args: ['install', '--target', '/home/ben/.azure/cliextensions/webapp', '/tmp/tmp4ly546cw/webapp-0.0.8-py2.py3-none-any.whl']
Running: ['/opt/az/bin/python3', '-m', 'pip', 'install', '--target', '/home/ben/.azure/cliextensions/webapp', '/tmp/tmp4ly546cw/webapp-0.0.8-py2.py3-none-any.whl', '-vv', '--disable-pip-version-check', '--no-cache-dir']
Traceback (most recent call last):
  File "/opt/az/lib/python3.6/runpy.py", line 183, in _run_module_as_main
    mod_name, mod_spec, code = _get_module_details(mod_name, _Error)
  File "/opt/az/lib/python3.6/runpy.py", line 142, in _get_module_details
    return _get_module_details(pkg_main_name, error)
  File "/opt/az/lib/python3.6/runpy.py", line 109, in _get_module_details
    __import__(pkg_name)
  File "/opt/az/lib/python3.6/site-packages/pip/__init__.py", line 28, in <module>
    from pip.vcs import git, mercurial, subversion, bazaar  # noqa
  File "/opt/az/lib/python3.6/site-packages/pip/vcs/mercurial.py", line 9, in <module>
    from pip.download import path_to_url
  File "/opt/az/lib/python3.6/site-packages/pip/download.py", line 36, in <module>
    from pip.utils.glibc import libc_ver
  File "/opt/az/lib/python3.6/site-packages/pip/utils/glibc.py", line 4, in <module>
    import ctypes
  File "/opt/az/lib/python3.6/ctypes/__init__.py", line 7, in <module>
    from _ctypes import Union, Structure, Array
ImportError: libffi.so.5: cannot open shared object file: No such file or directory

Command '['/opt/az/bin/python3', '-m', 'pip', 'install', '--target', '/home/ben/.azure/cliextensions/webapp', '/tmp/tmp4ly546cw/webapp-0.0.8-py2.py3-none-any.whl', '-vv', '--disable-pip-version-check', '--no-cache-dir']' returned non-zero exit status 1.
Pip failed so deleting anything we might have installed at /home/ben/.azure/cliextensions/webapp
An error occurred. Pip failed with status code 1. Use --debug for more information.
-----

Add note on how to test an extension directly from a PR

e.g.

docker run -it microsoft/azure-cli:latest
pip install --upgrade --target ~/.azure/cliextensions/servicebus "git+https://github.com/v-Ajnava/azure-cli-extensions@SBmasterExt#subdirectory=src/servicebus&egg=servicebus"

Add this to the PR template.

[Interactive] Unable to debug in Interactive mode

  1. I ran az interactive --debug to get debugging output for each of my calls. However, when I do that, any kind of dynamic tab completion (which occurs on basically every command because of resource group) causes the screen to be overrun with tons of debugging text related to the tab completion REST API calls. Thus you can't even see what you were typing. There doesn't seem to be a way to turn this off.

  2. I can't even run select calls with --debug. This just does nothing at all and prints normal output.

  3. I can't even paste from Notepad (for example) INTO az interactive, which would at least let me get around the tab completion calls that pollute my screen. This might be a shell thing.


Environment summary

Install Method: How did you install the CLI? (e.g. pip, interactive script, apt-get, Docker, MSI, nightly)
Answer here: dev_setup.py

CLI Version: What version of the CLI and modules are installed? (Use az --version)
Answer here: azure-cli (2.0.7+dev)

acr (2.0.5+dev)
acs (2.0.7+dev)
appservice (0.1.7+dev)
batch (3.0.0+dev)
billing (0.1.0+dev)
cdn (0.0.3+dev)
cloud (2.0.3+dev)
cognitiveservices (0.1.3+dev)
component (2.0.5+dev)
configure (2.0.7+dev)
consumption (0.1.0+dev)
core (2.0.7+dev)
cosmosdb (0.1.7+dev)
dla (0.0.7+dev)
dls (0.0.7+dev)
feedback (2.0.3+dev)
find (0.2.3+dev)
interactive (0.3.3+dev)
iot (0.1.6+dev)
keyvault (2.0.5+dev)
lab (0.0.5+dev)
monitor (0.0.5+dev)
network (2.0.7+dev)
nspkg (3.0.0+dev)
profile (2.0.5+dev)
rdbms (0.0.2+dev)
redis (0.2.4+dev)
resource (2.0.7+dev)
role (2.0.5+dev)
sf (1.0.2+dev)
sql (2.0.4+dev)
storage (2.0.7+dev)
taskhelp (0.1.2+dev)
testsdk (0.1.0+dev)
utility-automation (0.1.1)
vm (2.0.7+dev)

Python (Windows) 2.7.11 (v2.7.11:6d1b6a68f775, Dec 5 2015, 20:32:19) [MSC v.1500 32 bit (Intel)]

OS Version: What OS and version are you using?
Answer here: Win10 CU

Shell Type: What shell are you using? (e.g. bash, cmd.exe, Bash on Windows)
Answer here: cmd.exe

Change help for az webapp new

Extension name (the extension in question)

webapp

Description of issue (in as much detail as possible)

currently the help information for the command return the

Command
az webapp new: Create and deploy a node web app.

Requested changes:

  • add the callout for .net core apps
  • add explicit mention that the command is in preview

ML Server Administration utility not working on fresh DSVM

Extension name (the extension in question)

azure-ml-admin-cli

Description of issue (in as much detail as possible)

New Windows 2016 DSVM comes with ML Server 9.3.0 preinstalled. However, running Administration Utils immediately after installation results in an error:

C:\Program Files (x86)\Microsoft SDKs\Azure\CLI2\wbin>cd "C:\Program Files (x86)\Microsoft SDKs\Azure\CLI2\wbin" && az ml admin --help
az: error: argument _command_package: invalid choice: ml
usage: az [-h] [--verbose] [--debug] [--output {json,jsonc,table,tsv}]
          [--query JMESPATH]
          {acr,acs,aks,advisor,webapp,appservice,functionapp,backup,batch,batchai,billing,cdn,cloud,cognitiveservices,configure,consumption,container,cosmosdb,dla,dls,eventgrid,extension,feedback,find,interactive,iot,keyvault,lab,monitor,network,login,logout,account,mysql,postgres,redis,reservations,group,resource,provider,feature,tag,policy,lock,managedapp,role,ad,sf,sql,storage,disk,identity,image,snapshot,vm,vmss}
          ...

VM version: microsoft-ads:windows-data-science-vm:windows2016:18.02.00


C:\Program Files (x86)\Microsoft SDKs\Azure\CLI2\wbin>az --version
azure-cli (2.0.27)

acr (2.0.21)
acs (2.0.26)
advisor (0.1.2)
appservice (0.1.26)
backup (1.0.6)
batch (3.1.10)
batchai (0.1.5)
billing (0.1.7)
cdn (0.0.13)
cloud (2.0.12)
cognitiveservices (0.1.10)
command-modules-nspkg (2.0.1)
configure (2.0.14)
consumption (0.2.1)
container (0.1.18)
core (2.0.27)
cosmosdb (0.1.19)
dla (0.0.18)
dls (0.0.19)
eventgrid (0.1.10)
extension (0.0.9)
feedback (2.1.0)
find (0.2.8)
interactive (0.3.16)
iot (0.1.17)
keyvault (2.0.18)
lab (0.0.17)
monitor (0.1.2)
network (2.0.23)
nspkg (3.0.1)
profile (2.0.19)
rdbms (0.0.12)
redis (0.2.11)
reservations (0.1.1)
resource (2.0.23)
role (2.0.19)
servicefabric (0.0.10)
sql (2.0.21)
storage (2.0.25)
vm (2.0.26)

Python location 'C:\Program Files (x86)\Microsoft SDKs\Azure\CLI2\python.exe'
Extensions directory 'C:\Users\labdsvm-admin.azure\cliextensions'

Python (Windows) 3.6.1 (v3.6.1:69c0db5, Mar 21 2017, 17:54:52) [MSC v.1900 32 bit (Intel)]

Legal docs and information: aka.ms/AzureCliLegal

Simple default view for extension list-available

The list-available command is quite informative in its current form.

However it may be information overload for a casual user looking to see what extensions are available.

Consider a simple view by default when running list-available which shows bare minimum key properties of information (such as alias/id, name + summary, extension version(s) available with respective minCliCoreVersion, Python compatibility etc) and then an optional switch such as '--extended' which shows the full index detail.

[Proposal] Show extension version in extension reference docs

  • If the issue is to do with Azure CLI 2.0 in-particular, create an issue here at Azure/azure-cli

Extension name (the extension in question)

All extensions

Description of issue (in as much detail as possible)


The auto generating reference docs for extensions is a fantastic feature and alleviates extension teams having to build their own system for it.

However it is difficult to tell the extension version used. Theoretically the latest version should be used but given delays in syncing it would be nice to have the version somewhere obvious on the page so there is no second guessing. Not to mention having a version to point at for customers.

Interactive verbose mode with `--progress` has bad output

Description

Starting interactive mode with az interactive --verbose and running LRO commands with --progress causes bad outputs, no heartbeat, and the interactive UX is shown, but empty.

az>> az vm create -g MyRG -n MyVM --image UbuntuLTS --progress az>> Use existing SSH public key file: /Users/jasonsha/.ssh/id_rsa.pub Accepted: vm_deploy_YgbnsvjnymWhASelFeLWFIUfZTHpAfZZ (Microsoft.Resources/deployments) Succeeded: MyVMVMNic (Microsoft.Network/networkInterfaces) Succeeded: MyVMPublicIP (Microsoft.Network/publicIPAddresses) Succeeded: MyVMNSG (Microsoft.Network/networkSecurityGroups)

Error loading command module 'ml'


Environment summary

Linux UbuntuDesktop01 4.13.0-32-generic #35~16.04.1-Ubuntu SMP Thu Jan 25 10:13:43 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux

Install Method

https://docs.microsoft.com/en-us/azure/machine-learning/preview/deployment-setup-configuration
sudo -i
pip install azure-cli
pip install azure-cli-ml

Issue description

Following instructions at https://docs.microsoft.com/en-us/azure/machine-learning/preview/deployment-setup-configuration
-----------------------------------
Step: Environment Setup - To start the setup process, you need to register a few environment providers by entering the following commands:
az provider register -n Microsoft.MachineLearningCompute

Result of above command: Error loading command module 'ml'
------------------------------------
Command: az --debug
Result of above command:
Error loading command module 'ml'
Traceback (most recent call last):
  File "/usr/local/lib/python2.7/dist-packages/azure/cli/core/__init__.py", line 129, in _update_command_table_from_modules
    module_command_table = _load_module_command_loader(self, args, mod)
  File "/usr/local/lib/python2.7/dist-packages/azure/cli/core/commands/__init__.py", line 549, in _load_module_command_loader
    return _load_command_loader(loader, args, mod, 'azure.cli.command_modules.')
  File "/usr/local/lib/python2.7/dist-packages/azure/cli/core/commands/__init__.py", line 523, in _load_command_loader
    module = import_module(prefix + name)
  File "/usr/lib/python2.7/importlib/__init__.py", line 37, in import_module
    __import__(name)
  File "/usr/local/lib/python2.7/dist-packages/azure/cli/command_modules/ml/__init__.py", line 8, in <module>
    import azure.cli.command_modules.ml._help #pylint: disable=unused-import
  File "/usr/local/lib/python2.7/dist-packages/azure/cli/command_modules/ml/_help.py", line 6, in <module>
    from azure.cli.core.help_files import helps
ImportError: No module named help_files
------------------------------
/usr/local/lib/python2.7/dist-packages/azure/cli/command_modules/ml/_help.py
Line 6: from azure.cli.core.help_files import helps


Ctrl-c on interactive mode F1 crash

$ az interactive
****** F1 ********
Do you want command descriptions (y/n): ********ctrl+c***********
az>>
az>>

Traceback (most recent call last):
  File "/opt/az/lib/python3.6/site-packages/azure/cli/main.py", line 36, in main
    cmd_result = APPLICATION.execute(args)
  File "/opt/az/lib/python3.6/site-packages/azure/cli/core/application.py", line 211, in execute
    result = expanded_arg.func(params)
  File "/opt/az/lib/python3.6/site-packages/azure/cli/core/commands/__init__.py", line 346, in __call__
    return self.handler(*args, **kwargs)
  File "/opt/az/lib/python3.6/site-packages/azure/cli/core/commands/__init__.py", line 545, in _execute_command
    reraise(*sys.exc_info())
  File "/opt/az/lib/python3.6/site-packages/six.py", line 686, in reraise
    raise value
  File "/opt/az/lib/python3.6/site-packages/azure/cli/core/commands/__init__.py", line 522, in _execute_command
    result = op(client, **kwargs) if client else op(**kwargs)
  File "/opt/az/lib/python3.6/site-packages/azure/cli/command_modules/interactive/custom.py", line 14, in start_shell
    main(style=style)
  File "/opt/az/lib/python3.6/site-packages/azclishell/__main__.py", line 71, in main
    shell_app.run()
  File "/opt/az/lib/python3.6/site-packages/azclishell/app.py", line 691, in run
    document = self.cli.run(reset_current_buffer=True)
  File "/opt/az/lib/python3.6/site-packages/prompt_toolkit/interface.py", line 415, in run
    self.eventloop.run(self.input, self.create_eventloop_callbacks())
  File "/opt/az/lib/python3.6/site-packages/prompt_toolkit/eventloop/posix.py", line 56, in run
    assert not self._running
AssertionError

az webapp new should output website URL on completion

Extension name (the extension in question)

webapp

Description of issue (in as much detail as possible)

Currently, az webapp new does not include the website's URL as part of its output. The URL should be added to its output so the user can easily test it out.

az copy image extension doesn´t support tags

Extension name (the extension in question)

"extensionType": "whl",
"name": "image-copy-extension",
"version": "0.0.5"

Description of issue (in as much detail as possible)

Dear all,

I just write a shell based automation script to copy images from a source region in multiple target regions. I would like to change the existing tags of the source image for the target images.

I just think about to tag the target images later on, but that´s also not supported with the az cli.
Does someone know a workaround? Or it´s planned to implement tags for the extension?

Because the workaround which I use for now is like:

  1. Create managed disk and source image
  2. Create all target images with tags in the source region
  3. Copy the target images from the source region and delete the temporary images in the source region

In addition, I don´t want to use powershell scipts because all our automations are based on Perl or shell.

Regards Sandro

Support reference documentation generation for extensions

We do it for the CLI, it should be possible to do it for an extension as well.

A few things to consider:

  • We don't have all the source code for extensions in this repository as some extensions appear in the index but their source code is in a different repo.
  • Can we build ref docs only from .whl and not the source code?
  • Should we only provide online ref docs for extensions in the public index?
  • We can still make the script available for generation. The generated docs may not appear in online documentation though.

Bug: az webapp new - errors if missing node engine version in package.json

Extension name (the extension in question)

webapp

Description of issue (in as much detail as possible)

Many package.json files do not specify a node engine version. This value needs to have a default.

Repro:

bash-4.3# git clone https://github.com/scotch-io/node-todo.git
Cloning into 'node-todo'...
remote: Counting objects: 464, done.
remote: Total 464 (delta 0), reused 0 (delta 0), pack-reused 464
Receiving objects: 100% (464/464), 61.07 KiB | 0 bytes/s, done.
Resolving deltas: 100% (163/163), done.
Checking connectivity... done.
bash-4.3# cd node-todo/
bash-4.3# ls
README.md     README_es.md  app           config        license       package.json  public        server.js
bash-4.3# az webapp new -n test-node-todo
list index out of range
Traceback (most recent call last):
  File "/usr/local/lib/python3.6/site-packages/knack/cli.py", line 194, in invoke
    cmd_result = self.invocation.execute(args)
  File "/usr/local/lib/python3.6/site-packages/azure/cli/core/commands/__init__.py", line 331, in execute
    six.reraise(*sys.exc_info())
  File "/usr/local/lib/python3.6/site-packages/six.py", line 693, in reraise
    raise value
  File "/usr/local/lib/python3.6/site-packages/azure/cli/core/commands/__init__.py", line 304, in execute
    result = cmd(params)
  File "/usr/local/lib/python3.6/site-packages/azure/cli/core/commands/__init__.py", line 168, in __call__
    return super(AzCliCommand, self).__call__(*args, **kwargs)
  File "/usr/local/lib/python3.6/site-packages/knack/commands.py", line 109, in __call__
    return self.handler(*args, **kwargs)
  File "/usr/local/lib/python3.6/site-packages/azure/cli/core/__init__.py", line 348, in default_command_handler
    result = op(**command_args)
  File "/root/.azure/cliextensions/webapp/azext_webapp/custom.py", line 64, in create_deploy_webapp
    data = get_runtime_version_details(lang_details.get('file_loc'), language)
  File "/root/.azure/cliextensions/webapp/azext_webapp/create_util.py", line 61, in get_runtime_version_details
    version_detected = parse_node_version(file_path)[0]
IndexError: list index out of range
bash-4.3# 

Can't set environment variable in interactive

Description

Outline the issue here:
In the shell environment variables can't be set

Environment summary

Install Method: How did you install the CLI? (e.g. pip, interactive script, apt-get, Docker, MSI, nightly)
Answer here:

CLI Version: What version of the CLI and modules are installed? (Use az --version)
Answer here:

OS Version: What OS and version are you using?
Answer here:

Shell Type: What shell are you using? (e.g. bash, cmd.exe, Bash on Windows)
Answer here:

az login fails with azure-ml-admin-cli extension

Extension name (the extension in question)

azure-ml-admin-cli (0.0.1)

Description of issue (in as much detail as possible)

az login no longer works to login interactively after installing ML Server 9.3.0 with its CLI extension

PS C:\> az login
The behavior of this command has been altered by the following extension: azure-ml-admin-cli
login() missing 1 required positional argument: 'cmd'
Traceback (most recent call last):
  File "C:\Program Files (x86)\Microsoft SDKs\Azure\CLI2\lib\site-packages\knack\cli.py", line 197, in invoke
    cmd_result = self.invocation.execute(args)
  File "C:\Program Files (x86)\Microsoft SDKs\Azure\CLI2\lib\site-packages\azure\cli\core\commands\__init__.py", line 347, in execute
    six.reraise(*sys.exc_info())
  File "C:\Program Files (x86)\Microsoft SDKs\Azure\CLI2\lib\site-packages\six.py", line 693, in reraise
    raise value
  File "C:\Program Files (x86)\Microsoft SDKs\Azure\CLI2\lib\site-packages\azure\cli\core\commands\__init__.py", line 319, in execute
    result = cmd(params)
  File "C:\Program Files (x86)\Microsoft SDKs\Azure\CLI2\lib\site-packages\azure\cli\core\commands\__init__.py", line 180, in __call__
    return super(AzCliCommand, self).__call__(*args, **kwargs)
  File "C:\Program Files (x86)\Microsoft SDKs\Azure\CLI2\lib\site-packages\knack\commands.py", line 109, in __call__
    return self.handler(*args, **kwargs)
  File "C:\Program Files (x86)\Microsoft SDKs\Azure\CLI2\lib\site-packages\azure\cli\core\__init__.py", line 420, in default_command_handler
    result = op(**command_args)
  File "C:\Users\labdsvm-admin\.azure\cliextensions\azure-ml-admin-cli\azext_admin\custom.py", line 88, in mls_login
    msi_port=msi_port)
TypeError: login() missing 1 required positional argument: 'cmd'


Environment summary

Install Method: MSI
OS version: Windows Server 2016 Datacenter (DSVM)
Shell Type: Powershell

PS C:\> az --version
azure-cli (2.0.30)

acr (2.0.22)
acs (2.0.30)
advisor (0.5.0)
appservice (0.1.30)
backup (1.1.0)
batch (3.1.11)
batchai (0.1.6)
billing (0.1.7)
cdn (0.0.13)
cloud (2.0.12)
cognitiveservices (0.1.11)
command-modules-nspkg (2.0.1)
configure (2.0.14)
consumption (0.2.2)
container (0.1.20)
core (2.0.30)
cosmosdb (0.1.19)
dla (0.0.18)
dls (0.0.20)
eventgrid (0.1.11)
eventhubs (0.1.1)
extension (0.0.11)
feedback (2.1.0)
find (0.2.8)
interactive (0.3.18)
iot (0.1.18)
keyvault (2.0.20)
lab (0.0.20)
monitor (0.1.4)
network (2.0.26)
nspkg (3.0.2)
profile (2.0.21)
rdbms (0.2.0)
redis (0.2.11)
reservations (0.1.1)
resource (2.0.26)
role (2.0.21)
servicebus (0.1.1)
servicefabric (0.0.11)
sql (2.0.24)
storage (2.0.30)
vm (2.0.29)

Extensions:
azure-ml-admin-cli (0.0.1)
dns (0.0.2)

Python location 'C:\Program Files (x86)\Microsoft SDKs\Azure\CLI2\python.exe'
Extensions directory 'C:\Users\labdsvm-admin\.azure\cliextensions'

Python (Windows) 3.6.1 (v3.6.1:69c0db5, Mar 21 2017, 17:54:52) [MSC v.1900 32 bit (Intel)]


Reopened here based on comment in Azure/azure-cli#5991

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.