centos 安装pip 报错

在CentOS上安装pip时遇到SSL错误,提示无法连接HTTPS URL。解决方案包括检查openssl和openssl-devel的安装状态,如未安装则安装,已安装则重新编译Python,取消Setup文件中关于SSL的注释,然后重新编译并安装。完成这些步骤后,pip安装将恢复正常。
摘要由CSDN通过智能技术生成

下载get-pip.py文件后
用python get-pip.py 安装报以下错误:

pip is configured with locations that require TLS/SSL, however the ssl
module in Python is not available. Collecting xxx Could not fetch
URL https://pypi.python.org/simple/xxxx/: There was a problem
confirming the ssl certificate: Can’t connect to HTTPS URL because the
SSL module is not available. - skipping Could not find a version that
satisfies the requirement xxx (from versions: ) No matching
distribution found for xxx

执行python ,进入python 命令行:

import ssl 
Traceback (most recent call last): 
File “”, line 1, in 
File “/usr/loc
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值