为什么在将Python升级到3.8之后Pip不能工作?

2024-04-25 23:51:47 发布

您现在位置:Python中文网/ 问答频道 /正文

我在用python3.6.8和pip3开发一个2D游戏。一切正常。然后我下载并安装了Python3.8。现在,皮普根本不起作用。以下是我在运行“pip3 install arcade”时遇到的错误:

WARNING: pip is configured with locations that require TLS/SSL, however the ssl module in Python is not available.
Collecting arcade
  WARNING: Retrying (Retry(total=4, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError("Can't connect to HTTPS URL because the SSL module is not available.")': /simple/arcade/
  WARNING: Retrying (Retry(total=3, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError("Can't connect to HTTPS URL because the SSL module is not available.")': /simple/arcade/
  WARNING: Retrying (Retry(total=2, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError("Can't connect to HTTPS URL because the SSL module is not available.")': /simple/arcade/
  WARNING: Retrying (Retry(total=1, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError("Can't connect to HTTPS URL because the SSL module is not available.")': /simple/arcade/
  WARNING: Retrying (Retry(total=0, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError("Can't connect to HTTPS URL because the SSL module is not available.")': /simple/arcade/
  Could not fetch URL https://pypi.org/simple/arcade/: There was a problem confirming the ssl certificate: HTTPSConnectionPool(host='pypi.org', port=443): Max retries exceeded with url: /simple/arcade/ (Caused by SSLError("Can't connect to HTTPS URL because the SSL module is not available.")) - skipping
  ERROR: Could not find a version that satisfies the requirement arcade (from versions: none)
ERROR: No matching distribution found for arcade
WARNING: pip is configured with locations that require TLS/SSL, however the ssl module in Python is not available.
Could not fetch URL https://pypi.org/simple/pip/: There was a problem confirming the ssl certificate: HTTPSConnectionPool(host='pypi.org', port=443): Max retries exceeded with url: /simple/pip/ (Caused by SSLError("Can't connect to HTTPS URL because the SSL module is not available.")) - skipping

请帮忙,我想继续做我的游戏。在


Tags: thenoneurlsslbyisconnectnot
1条回答
网友
1楼 · 发布于 2024-04-25 23:51:47

错误很明显。您的ssl模块已损坏,因此无法连接到HTTPS站点(如PyPI)。也许您安装了错误的Python版本,或者它是在运行时依赖于一个库(比如OpenSSL)上构建的,而这个库没有兼容的版本。如果没有进一步的信息,我们无法知道是什么导致了这个问题,只知道您的python3.8安装被破坏了。在

如果还没有python3.8的Mint包,那么您可以始终build it from source,但是一定要先安装所有的依赖项,否则最后只会出现另一个失败的安装。在

相关问题 更多 >