我使用的是Python 3.6。当我尝试使用pip3安装“模块”时,我遇到了这个问题:
pip is configured with locations that require TLS/SSL, however the ssl module in Python is not available
我使用的是Python 3.6。当我尝试使用pip3安装“模块”时,我遇到了这个问题:
pip is configured with locations that require TLS/SSL, however the ssl module in Python is not available
当前回答
如果您已经通过scoop安装了anaconda,并且在conda环境中使用pip时遇到此错误,您可以通过…
将这些添加到路径中
C:\Users\YOUR_USERNAME\scoop\apps\anaconda3\current
C:\Users\YOUR_USERNAME\scoop\apps\anaconda3\current\Scripts
C:\Users\YOUR_USERNAME\scoop\apps\anaconda3\current\Library
C:\Users\YOUR_USERNAME\scoop\apps\anaconda3\current\Library\bin
通过scoop安装openssl
scoop install openssl
并从..复制以下dll。\anaconda3\Library\bin到..\anaconda3\ dll
引用:
https://stackoverflow.com/a/54897379 https://stackoverflow.com/a/60405693
其他回答
我遇到了这个问题!我不小心安装了32位版本的Miniconda3。确保你选择的是64位版本!
对于OpenSUSE,以同样的方式,但对上面列出的包做了一些更改:
zypper install zlib-devel libopenssl-devel ncurses-devel sqlite3-devel readline-devel tk-devel gdbm-devel libpcap-devel xz-devel
然后cd到Python源代码dir和
make
make install
or
make
make altinstall
也许
ln -s /usr/local/lib64/python3.6/lib-dynload/ /usr/local/lib/python3.6/lib-dynload
应该为OpenSUSE用户执行。请参见Python 3.7安装无法在openSUSE Leap 42.3上工作
只要尝试通过Anaconda提示安装即可
为我工作。
sudo apt-get install libssl-dev
使用此选项为pip启用ssl。 如果有人遇到问题请告诉我。
我简单地用以下命令解决了这个问题:
Brew升级python@3.9
这个版本默认包含SSL !