Skip to content

support for python 3.8 #11239

@chi42

Description

@chi42

Is your feature request related to a problem? Please describe.
Unable to install Azure CLI on Arch Linux due to the CLI not supporting python 3.8. Some APIs that the CLI relies on were deprecated and removed in python 3.8.

Examples of deprecated APIs that I'm hitting:

 az                  
Traceback (most recent call last):
  File "/usr/lib64/python3.8/runpy.py", line 192, in _run_module_as_main
    return _run_code(code, main_globals, None,
  File "/usr/lib64/python3.8/runpy.py", line 85, in _run_code
    exec(code, run_globals)
  File "/home/chi/lib/azure-cli/lib/python3.8/site-packages/azure/cli/__main__.py", line 33, in <module>
    az_cli = get_default_cli()
  File "/home/chi/lib/azure-cli/lib/python3.8/site-packages/azure/cli/core/__init__.py", line 546, in get_default_cli
    return AzCli(cli_name='az',
  File "/home/chi/lib/azure-cli/lib/python3.8/site-packages/azure/cli/core/__init__.py", line 55, in __init__
    SESSION.load(os.path.join(azure_folder, 'az.sess'), max_age=3600)
  File "/home/chi/lib/azure-cli/lib/python3.8/site-packages/azure/cli/core/_session.py", line 46, in load
    if st.st_mtime + max_age < time.clock():
AttributeError: module 'time' has no attribute 'clock'

and:

AttributeError: module 'platform' has no attribute 'linux_distribution'

Describe the solution you'd like
A clear and concise description of what you want to happen.

Describe alternatives you've considered
A clear and concise description of any alternative solutions or features you've considered.

Additional context
Add any other context or screenshots about the feature request here.

Metadata

Metadata

Labels

CoreCLI core infrastructure

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions