python3.6 SSL module is not available

时间:2022-03-25 09:32:31

pip is configured with locations that require TLS/SSL, however the ssl module in Python is not available.
Collecting requests
Could not fetch URL https://pypi.python.org/simple/requests/: There was a problem confirming the ssl certificate: Can't connect to HTTPS URL because the SSL module is not available. - skipping
Could not fetch URL https://www.piwheels.hostedpi.com/simple/requests/: 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 requests (from versions: )
No matching distribution found for requests

修改 ~/.pip/pip.conf文件

[global] index-url = http://mirrors.aliyun.com/pypi/simple/  #可以手工指定是http的或者https的  [install] trusted-host=mirrors.aliyun.com