简体   繁体   中英

Python installation issues

I am trying to install python latest version in my Ubuntu 18.04, but I am getting the following error:

python setup.py install 

File "setup.py", line 354 + f'found:\n{tzpaths!r}\nwith invalid paths:\n' ^

I tried:

pip install Python-3.10.5 

[sudo] password for rb: 
The directory '/home/rb/.cache/pip/http' or its parent directory is not owned by the current user and the cache has been disabled. Please check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag. The directory '/home/rb/.cache/pip' or its parent directory is not owned by the current user and caching wheels has been disabled. check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag. Collecting Python-3.10.5 Could not find a version that satisfies the requirement Python-3.10.5 (from versions: ) No matching distribution found for Python-3.10.5

I tried without sudo:

pip install Python-3.10.5 Collecting Python-3.10.5 Could not find a version that satisfies the requirement Python-3.10.5 (from versions: ) No matching distribution found for Python-3.10.5

Could you please provide some solution?

try using apt sudo apt install python3

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM