azure-cli icon indicating copy to clipboard operation
azure-cli copied to clipboard

Missing antlr4, Command not working on Ubuntu Server 20.04 - az vm list-ip-addresses

Open viniciusbuscacio opened this issue 6 years ago • 5 comments

This is autogenerated. Please review and update as needed.

Describe the bug

Command Name az vm list-ip-addresses

Errors:

No module named 'antlr4'
Traceback (most recent call last):
lib/python3/dist-packages/knack/cli.py, ln 206, in invoke
    cmd_result = self.invocation.execute(args)
azure/cli/core/commands/__init__.py, ln 528, in execute
    self.commands_loader.load_arguments(command)
dist-packages/azure/cli/core/__init__.py, ln 300, in load_arguments
    loader.load_arguments(command)  # this adds entries to the argument registries
azure/cli/command_modules/vm/__init__.py, ln 31, in load_arguments
    from azure.cli.command_modules.vm._params import load_arguments
azure/cli/command_modules/vm/_params.py, ln 31, in <module>
    from azure.cli.command_modules.monitor.actions import get_period_type
azure/cli/command_modules/monitor/actions.py, ln 7, in <module>
    import antlr4
ModuleNotFoundError: No module named 'antlr4'

To Reproduce:

Steps to reproduce the behavior. Note that argument values have been redacted, as they may contain sensitive information.

  • Put any pre-requisite steps here...
  • az vm list-ip-addresses

Expected Behavior

Environment Summary

Linux-5.4.0-1020-azure-x86_64-with-glibc2.29
Python 3.8.2
Shell: bash

azure-cli 2.0.81 *

Extensions:
azure-devops 0.17.0

Additional Context

viniciusbuscacio avatar Jul 26 '20 02:07 viniciusbuscacio

@qwordy please take a look

yonzhan avatar Jul 26 '20 13:07 yonzhan

Are you using the bundled Azure CLI of Ubuntu? The package is old and has some problems. Could you install the latest version and retry? https://docs.microsoft.com/en-us/cli/azure/install-azure-cli?view=azure-cli-latest

qwordy avatar Jul 27 '20 03:07 qwordy

Are you using the bundled Azure CLI of Ubuntu? The package is old and has some problems. Could you install the latest version and retry? https://docs.microsoft.com/en-us/cli/azure/install-azure-cli?view=azure-cli-latest

OK, I'll check it.

viniciusbuscacio avatar Jul 31 '20 19:07 viniciusbuscacio

hi @viniciusbuscacio does installing latest version resolved your issue?

yungezz avatar Sep 14 '20 04:09 yungezz

Close since no reply. This a common issue and the solution has been verified by many users.

qwordy avatar Sep 21 '20 06:09 qwordy