ModuleNotFoundError: No module named 'azure.mgmt.security.models._security_center_enums'; 'azure.mgmt.security.models' is not a package on Kali linux
See original GitHub issueThis is autogenerated. Please review and update as needed.
Describe the bug
Command Name
az security pricing list
Errors:
The command failed with an unexpected error. Here is the traceback:
No module named 'azure.mgmt.security.models._security_center_enums'; 'azure.mgmt.security.models' is not a package
Traceback (most recent call last):
File "/usr/lib/python3/dist-packages/knack/cli.py", line 233, in invoke
cmd_result = self.invocation.execute(args)
File "/usr/lib/python3/dist-packages/azure/cli/core/commands/__init__.py", line 561, in execute
self.commands_loader.load_arguments(command)
File "/usr/lib/python3/dist-packages/azure/cli/core/__init__.py", line 507, in load_arguments
self.command_table[command].load_arguments() # this loads the arguments via reflection
File "/usr/lib/python3/dist-packages/azure/cli/core/commands/__init__.py", line 318, in load_arguments
super(AzCliCommand, self).load_arguments()
File "/usr/lib/python3/dist-packages/knack/commands.py", line 104, in load_arguments
cmd_args = self.arguments_loader()
File "/usr/lib/python3/dist-packages/azure/cli/core/commands/command_operation.py", line 125, in arguments_loader
op = self.get_op_handler(self.op_path)
File "/usr/lib/python3/dist-packages/azure/cli/core/commands/command_operation.py", line 59, in get_op_handler
handler = import_module(mod_to_import)
File "/usr/lib/python3.10/importlib/__init__.py", line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "<frozen importlib._bootstrap>", line 1050, in _gcd_import
File "<frozen importlib._bootstrap>", line 1027, in _find_and_load
File "<frozen importlib._bootstrap>", line 1006, in _find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 688, in _load_unlocked
File "<frozen importlib._bootstrap_external>", line 883, in exec_module
File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed
File "/usr/lib/python3/dist-packages/azure/cli/command_modules/security/custom.py", line 35, in <module>
from azure.mgmt.security.models._security_center_enums import Enum69
ModuleNotFoundError: No module named 'azure.mgmt.security.models._security_center_enums'; 'azure.mgmt.security.models' is not a package
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 security pricing list
Expected Behavior
Environment Summary
Linux-5.15.0-kali3-amd64-x86_64-with-glibc2.35, Kali GNU/Linux Rolling
Python 3.10.5
Installer: DEB
azure-cli 2.42.0
Extensions:
azure-devops 0.24.0
Dependencies:
msal 1.20.0
azure-mgmt-resource 21.2.1
Additional Context
Issue Analytics
- State:
- Created 10 months ago
- Comments:5 (2 by maintainers)
Top Results From Across the Web
No module named 'azure.mgmt.managementgroups ... - GitHub
Package Name: azure collection Package Version: 1.10 Operating System: RHEL Python ... The error was: ModuleNotFoundError: No module named ...
Read more >ModuleNotFoundError: No module named 'azure.mgmt ...
After upgrading ansible to version 2.10.5 and python3.8.10 my playbook.yml fails with this error. ModuleNotFoundError: No module named 'azure.
Read more >ModuleNotFoundError: No module named 'azure-mgmt-storage'
Hi, My Python program is throwing following error: ModuleNotFoundError: No module named 'azure-mgmt-storage' How to remove the.
Read more >Modulenotfounderror: no module named azure ( Solved )
ModuleNotFoundError is a python error. In most cases, you will get errors when you are importing a specific python package into your system....
Read more >Kali Linux 2022.4 brings new tools, Azure images and desktop ...
The Kali Linux distribution was developed for network penetration tests, security audits and cybersecurity research. The team provided various ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@kabene I checked now with Kali and I am able to reproduce your error.
I am checking now internally on this issue and get back to you at the earliest. Thanks.
@SaurabhSharma-MSFT what happen if you remove azure.mgmt.security.models._security_center_enums’; ‘azure.mgmt.security.models’ because my kali get that it is not a package and i cannot add it manually.
I’ve tried multiple times to uninstall the cli and install it again but it seems to still be broken