问题描述
我刚刚安装了Azure CLI,并尝试运行az --version。文件az.sess获得权限被拒绝的例外情况
OS - Microsoft Windows 10 Enterprise (10.0.19041 Build 19041)
Azure CLI Version Installed (latest) - 2.10.1
尝试以管理员身份运行Power Shell,并确保CLI安装不是只读的
C:\WINDOWS\system32> az --version
Traceback (most recent call last):
File "C:\Users\VSSADM~1\AppData\Local\Temp\pip-unpacked-wheel-d55550gx\azure\cli\core\_session.py",line 47,in load
File "C:\Users\VSSADM~1\AppData\Local\Temp\pip-unpacked-wheel-d55550gx\azure\cli\core\_session.py",line 65,in save
File "codecs.py",line 897,in open
PermissionError: [Errno 13] Permission denied: 'C:\\Users\\mmodi\\.azure\\az.sess'
During handling of the above exception,another exception occurred:
Traceback (most recent call last):
File "runpy.py",line 193,in _run_module_as_main
File "runpy.py",line 85,in _run_code
File "C:\Users\VSSADM~1\AppData\Local\Temp\pip-unpacked-wheel-clkvqii1\azure\cli\__main__.py",line 35,in <module>
File "C:\Users\VSSADM~1\AppData\Local\Temp\pip-unpacked-wheel-d55550gx\azure\cli\core\__init__.py",line 848,in get_default_cli
File "C:\Users\VSSADM~1\AppData\Local\Temp\pip-unpacked-wheel-d55550gx\azure\cli\core\__init__.py",in __init__
File "C:\Users\VSSADM~1\AppData\Local\Temp\pip-unpacked-wheel-d55550gx\azure\cli\core\_session.py",line 61,in save
File "codecs.py",in open
PermissionError: [Errno 13] Permission denied: 'C:\\Users\\<User Name>\\.azure\\az.sess'
解决方法
暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!
如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。
小编邮箱:dio#foxmail.com (将#修改为@)