参考:https://blog.csdn.net/dou3516/article/details/111881479
使用pip install 某个包的时候报错ModuleNotFoundError: No module named ‘某个包’ ,错误原因是:
There was a problem confirming the ssl certificate: HTTPSConnectionPool(host=‘pypi.tuna.tsinghua.edu.cn’, port=443): Max retries exceeded with url: /simple/pip/ (Caused by SSLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate
此时需要获得 ssl证书的认证,需要在原来的安装命令后增加:-i http://mirrors.aliyun.com/pypi/simple --trusted-host mirrors.aliyun.com (也可换其他源)
例如:
pip install scipy
改为:文章来源:https://www.toymoban.com/news/detail-739547.html
pip install scipy -i http://mirrors.aliyun.com/pypi/simple --trusted-host mirrors.aliyun.com
说明:这是阿里源 --trusted-host mirrors.aliyun.com 这是为了获得ssl证书的认证文章来源地址https://www.toymoban.com/news/detail-739547.html
到了这里,关于There was a problem confirming the ssl certificate的文章就介绍完了。如果您还想了解更多内容,请在右上角搜索TOY模板网以前的文章或继续浏览下面的相关文章,希望大家以后多多支持TOY模板网!