Linux下安装python后遇到的一些错误提示

缺少openssl相关模块

pip is configured with locations that require TLS/SSL, however the ssl module in Python is not available.

解决方法

  • Fedora
sudo dnf install openssl openssl-devel
  • Ubuntu
sudo apt install openssl libssl-dev

pip or setuptools未安装最新版本

The directory '/home/amosniu/.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.

解决方法:

pip install --user --upgrade pip 
pip install --user --upgrade setuptools
©著作权归作者所有,转载或内容合作请联系作者
平台声明:文章内容(如有图片或视频亦包括在内)由作者上传并发布,文章内容仅代表作者本人观点,简书系信息发布平台,仅提供信息存储服务。

推荐阅读更多精彩内容