PIP:WARNING: Retrying (Retry(total=4, connect=None, read=None, redirect=None, status=None))

840次阅读
没有评论

共计 1825 个字符,预计需要花费 5 分钟才能阅读完成。

使用 PIP 安装时,提示如下错误:

WARNING: Retrying (Retry(total=4, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<urllib3.connection.HTTPConnection object at 0x7f11435ebfd0>: Failed to establish a new connection: [Errno -2] Name or service not known')': /pypi/simple/psutil/
WARNING: Retrying (Retry(total=3, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<urllib3.connection.HTTPConnection object at 0x7f11435eb3d0>: Failed to establish a new connection: [Errno -2] Name or service not known')': /pypi/simple/psutil/
WARNING: Retrying (Retry(total=2, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<urllib3.connection.HTTPConnection object at 0x7f114303f0a0>: Failed to establish a new connection: [Errno -2] Name or service not known')': /pypi/simple/psutil/
WARNING: Retrying (Retry(total=1, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<urllib3.connection.HTTPConnection object at 0x7f114303fe20>: Failed to establish a new connection: [Errno -2] Name or service not known')': /pypi/simple/psutil/
WARNING: Retrying (Retry(total=0, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<urllib3.connection.HTTPConnection object at 0x7f114303f850>: Failed to establish a new connection: [Errno -2] Name or service not known')': /pypi/simple/psutil/
ERROR: Could not find a version that satisfies the requirement psutil (from versions: none)
ERROR: No matching distribution found for psutil

可以通过更换源来解决,并且忽略证书验证:

pip install requests -i http://mirrors.aliyun.com/pypi/simple --trusted-host mirrors.aliyun.com

下面是收集的一些国内的 pip 源:

阿里云 http://mirrors.aliyun.com/pypi/simple/
中国科技大学 https://pypi.mirrors.ustc.edu.cn/simple/
豆瓣 (douban) http://pypi.douban.com/simple/
清华大学 https://pypi.tuna.tsinghua.edu.cn/simple/
中国科学技术大学 http://pypi.mirrors.ustc.edu.cn/simple/

正文完
加入官方交流QQ群:778957856
post-qrcode
 0
clark
版权声明:本站原创文章,由 clark 2023-03-19发表,共计1825字。
转载说明:除特殊说明外本站文章皆由CC-4.0协议发布,转载请注明出处。
评论(没有评论)