pip is configured with locations that require TLS/SSL, however the ssl module in Python is not available. WARNING: Retrying
时间: 2023-09-22 13:13:00 浏览: 188
Ubuntu/Deepin下Python3.8出现SSL错误的解决方案
这个问题的原因是Python模块ssl不可用,导致pip在配置TLS/SSL时出现问题。
解决这个问题的方法有种:
1.重新编译安装Python:可以使用以下命令重新编译和安装Python,这将包括ssl模块并解决问题:
Python-3.7.12 % ./configure --with-ssl
Python-3.7.12 % make
Python-3.7.12 % sudo make install [2]
2.切换国内镜像站点:尝试将pip的镜像站点切换到国内镜像站点,例如阿里云镜像站点。可以使用以下命令进行配置:
pip config set global.trusted-host mirrors.aliyun.com
pip config set global.index-url https://mirrors.aliyun.com/pypi/simple
通过执行以上方法中的任何一种,您可以解决pip在配置TLS/SSL时ssl模块不可用的问题。<span class="em">1</span><span class="em">2</span><span class="em">3</span>
#### 引用[.reference_title]
- *1* [讲真的,我需要帮助,这样的问题我在装TENSORFLOW也遇到过,求大神们告诉我这是那里的错误呀](https://download.csdn.net/download/weixin_38526751/14884786)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v93^chatsearchT3_1"}}] [.reference_item style="max-width: 50%"]
- *2* *3* [pip is configured with locations that require TLS/SSL, however the ssl module in Python is not avail](https://blog.csdn.net/asdcls/article/details/122500578)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v93^chatsearchT3_1"}}] [.reference_item style="max-width: 50%"]
[ .reference_list ]
阅读全文