/proc/stat permission denied traceback after running successful commands in Termux on Android
- Dominant language
- Python
- Stars
- 4.6k
- Forks
- 3.5k
- Avg merge
- 3d 2h
- Merged PRs (30d)
- 60
Description
> ### `az feedback` auto-generates most of the information requested below, as of CLI version 2.0.62
**Describe the bug**
I installed the azure cli on Termux on my Samsung S20 Plus, currently running Android 11, and almost everything works. In fact, I'm not sure what isn't working except for the following traceback I receive after the completion of every single command:
```
Traceback (most recent call last): File "/data/data/com.termux/files/home/.local/pipx/venvs/azure-cli/lib/python3.9/site-packages/azure/cli/__main__.py", line 60, in raise ex File "/data/data/com.termux/files/home/.local/pipx/venvs/azure-cli/lib/python3.9/site-packages/azure/cli/__main__.py", line 53, in sys.exit(exit_code) SystemExit: 0 During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/data/data/com.termux/files/home/.local/pipx/venvs/azure-cli/lib/python3.9/site-packages/psutil/_common.py", line 402, in wrapper return cache[key] KeyError: (('/proc',), frozenset()) During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/data/data/com.termux/files/home/.local/pipx/venvs/azure-cli/lib/python3.9/site-packages/psutil/_pslinux.py", line 303, in set_scputimes_ntuple("/proc") File "/data/data/com.termux/files/home/.local/pipx/venvs/azure-cli/lib/python3.9/site-packages/psutil/_common.py", line 404, in wrapper ret = cache[key] = fun(*args, **kwargs) File "/data/data/com.termux/files/home/.local/pipx/venvs/azure-cli/lib/python3.9/site-packages/psutil/_pslinux.py", line 270, in set_scputimes_ntuple with open_binary('%s/stat' % procfs_path) as f: File "/data/data/com.termux/files/home/.local/pipx/venvs/azure-cli/lib/python3.9/site-packages/psutil/_common.py", line 710, in open_binary return open(fname, "rb", **kwargs) PermissionError: [Errno 13] Permission denied: '/proc/stat'
```
**To Reproduce**
I believe it just involves install azure-cli on Termux. I used [these instructions](https://www.brianlinkletter.com/install-azure-cli-on-your-android-phone/) to install the dependencies, then used `pipx` to install azure-cli. It also requires a version of Android 6 or greater, as it limits permissions to `/proc/stat` to system apps. I am using an unrooted, stock device with Knox enabled.
**Expected behavior**
There shouldn't be a traceback, and from what I can tell, it does not affect functionality. It could effectively be garbage, but could be more.
**Environment summary**
Android 11 on Verizon Samsung S20 Plus
Azure CLI 2.17.1
Python 3.9.1
Termux 0.101
Contributor guide
Assessment
This issue has not been assessed yet.