我有 anaconda 包并运行 Spyder。这是我的系统信息:
anaconda 2018.12 py37_0
Python 3.7.1
pip 18.1
Dell Inspiron 13 7000 64-bit
我无法在命令提示符下使用 pip 安装任何东西。例如,我在尝试安装 numpy 时得到以下信息(我已经通过 anaconda 安装了):
pip is configured with locations that require TLS/SSL, however the ssl module in Python is not available.
Requirement already satisfied: numpy in c:\users\uday rallabhandi\anaconda3\lib\site-packages (1.15.4)
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
请帮助我理解为什么会这样。
最佳答案
这是我使用 Anaconda 在 Windows 10 上纠正错误的过程:
- 在我的环境变量中添加了以下路径:
- /AppData/Local/Continuum/Anaconda3
- /AppData/Local/Continuum/Anaconda3/Scripts
- /AppData/Local/Continuum/Anaconda3/Library
- /AppData/Local/Continuum/Anaconda3/Library/Bin
在这个阶段,错误信息仍然存在。
- 我从 Anaconda Prompt 安装了最新版本的 pip:
python -m pip install --upgrade pip
这似乎更正了 DLL 冲突。
关于python - "pip is configured with locations that require TLS/SSL, however the ssl module in Python is not available",我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/54394764/