pip Could not find a version that satisfies the requirement *(from -r requirements.txt)

Posted Recar

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了pip Could not find a version that satisfies the requirement *(from -r requirements.txt)相关的知识,希望对你有一定的参考价值。

在制作一个docker镜像的时候
RUN pip install -r requirements.txt -i http://pypi.tuna.tsinghua.edu.cn/simple

但是报错说 找不到这个版本 我就去pypi搜 发现是有这个版本的
那么接下来怎么查看呢 pip —help 可以看到很多帮助信息于是详细输出 比如加上 -vvv 就输出详细信息

RUN pip install -r requirements.txt -i http://pypi.tuna.tsinghua.edu.cn/simple -vvv
好的报错的详细信息输出
SSLError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:590)
ssl 的问题 因为请求的pip源是https导致的
解决

注意这里写的是http不是https
pip install -r requirements.txt -i http://pypi.tuna.tsinghua.edu.cn/simple --trusted-host pypi.tuna.tsinghua.edu.cn

参考
https://stackoverflow.com/questions/25981703/pip-install-fails-with-connection-error-ssl-certificate-verify-failed-certi

以上是关于pip Could not find a version that satisfies the requirement *(from -r requirements.txt)的主要内容,如果未能解决你的问题,请参考以下文章

pip install yaml报错ERROR:Could not find a version that satisfies the requirement yaml

pip ERROR: Could not find a version that satisfies the requirement loguru (from versions: none)

Could not find a version that satisfies the requtrement pandas

pip3版本已经是最新,安装openxl失败,Could not find a version that satisfies the requirement openxl

pip Could not find a version that satisfies the requirement *(from -r requirements.txt)

pip Could not find a version that satisfies the requirement *(from -r requirements.txt)