python3.6 使用pip 出现 TLS/SSL问题?

今天在在centos 6.9上 安装python3.6后 使用pip 安装模块,提示如下错误:

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

解决方法:

1、安装 openssl openssl-devel (openssl-dev)
2、编译安装python,添加如下选项
./configure –with-ssl
3、make && sudo make install
4、brew 的话,装完 openssl 的直接 brew install python3 也没问题。

点赞

Leave a Reply

Your email address will not be published. Required fields are marked *