【发布时间】:2021-03-09 09:53:27
【问题描述】:
我在 Ubuntu1604 上使用带有 pip 21.0.1 的 python 3.7。我无法安装任何带有错误的python包
yc_qian@NiBaBa:~$ pip install pyopenssl
Defaulting to user installation because normal site-packages is not writeable
Looking in indexes: https://pypi.tuna.tsinghua.edu.cn/simple
WARNING: Retrying (Retry(total=4, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError(SSLEOFError(8, 'EOF occurred in violation of protocol (_ssl.c:1076)'))': /simple/pyopenssl/
WARNING: Retrying (Retry(total=3, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError(SSLEOFError(8, 'EOF occurred in violation of protocol (_ssl.c:1076)'))': /simple/pyopenssl/
WARNING: Retrying (Retry(total=2, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError(SSLEOFError(8, 'EOF occurred in violation of protocol (_ssl.c:1076)'))': /simple/pyopenssl/
WARNING: Retrying (Retry(total=1, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError(SSLEOFError(8, 'EOF occurred in violation of protocol (_ssl.c:1076)'))': /simple/pyopenssl/
WARNING: Retrying (Retry(total=0, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError(SSLEOFError(8, 'EOF occurred in violation of protocol (_ssl.c:1076)'))': /simple/pyopenssl/
Could not fetch URL https://pypi.tuna.tsinghua.edu.cn/simple/pyopenssl/: There was a problem confirming the ssl certificate: HTTPSConnectionPool(host='pypi.tuna.tsinghua.edu.cn', port=443): Max retries exceeded with url: /simple/pyopenssl/ (Caused by SSLError(SSLEOFError(8, 'EOF occurred in violation of protocol (_ssl.c:1076)'))) - skipping
ERROR: Could not find a version that satisfies the requirement pyopenssl
ERROR: No matching distribution found for pyopenssl
Could not fetch URL https://pypi.tuna.tsinghua.edu.cn/simple/pip/: 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(SSLEOFError(8, 'EOF occurred in violation of protocol (_ssl.c:1076)'))) - skipping
我在github 上发现了类似的问题,但不知道如何解决。我也试过降级pip,但是命令也使用pip,所以碰到了同样的错误...
我该如何解决这个问题?
【问题讨论】:
-
在我的机器上运行 Fiddler 时收到了类似的错误。如果您正在运行它,请尝试关闭它。
-
@FelixEklöf 没有提琴手,我确实运行了一个 VPN,但如果我关闭它并再次尝试安装没有任何区别..