首页 > 其他分享 >pip install报错"Can't connect to HTTPS URL because the SSL module is not available"

pip install报错"Can't connect to HTTPS URL because the SSL module is not available"

时间:2023-11-25 17:12:11浏览次数:28  
标签:available None because URL module SSL 报错 connect

一、故障现象

[root@jenkins /data/package/openssl-1.1.1n]# pip3 install emoji
WARNING: pip is configured with locations that require TLS/SSL, however the ssl module in Python is not available.
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/emoji/
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/emoji/
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/emoji/
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/emoji/
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/emoji/
Could not fetch URL https://pypi.org/simple/emoji/: There was a problem confirming the ssl certificate: HTTPSConnectionPool(host='pypi.org', port=443): Max retries exceeded with url: /simple/emoji/ (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 emoji (from versions: none)
ERROR: No matching distribution found for emoji
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

pip时install报错Can't connect to HTTPS URL because the SSL module is not available

二、解决思路

安装 openssl-1.1.1
下载openssl1.1.1

wget https://www.openssl.org/source/openssl-1.1.1n.tar.gz --no-check-certificate 
解压
tar -zxf openssl-1.1.1n.tar.gz 
进入目录
cd openssl-1.1.1n
设置安装目录 可以自定义 但是要记住,后面会用到
./config--prefix=/data/software/openssl
编译并安装
make -j && make install 


cd /data/package/Python-3.11.5
make  clean
./configure --prefix=/data/software/python3 --with-openssl=/data/software/openssl --with-openssl-rpath=auto
make -j && make install

标签:available,None,because,URL,module,SSL,报错,connect
From: https://www.cnblogs.com/world-of-yuan/p/17855748.html

相关文章

  • 奇怪编译报错!
    #defineLOGE(fmt,...)do{\ char*buf=(char*)malloc(1024);\ if(buf){\ char*file;\ memset(buf,0,1024);\ file=(char*)strrchr(__FILE__,'/');\ if(!file){\ file=(char*)strrchr(__FILE__,'\\');\ }\ ......
  • winform 使用了invoke还是报错 线程间操作无效: 从不是创建控件“Form2”的线程访问它
    winform开发中,遇到“线程间操作无效:从不是创建控件“Form2”的线程访问它”,明明使用了网上说的this.invoke,怎么还是会报这个错误呢?代码如下,由于是测试configureAwait功能时发现的,所以带了它的一些使用 privateasyncvoidbutton7_Click(objectsender,EventArgse)//点......
  • 如何忽略 Python 中异常的报错
    在Python编程中,异常是一种常见的情况,可能会导致程序中断或产生错误。然而,并非所有的异常都需要立即处理,有时候我们希望忽略某些异常并继续执行程序。本文将介绍如何在Python中忽略异常,并提供一些示例和注意事项。try-except块:在Python中,我们可以使用try-except块来捕获并......
  • npm install xxxx 报错 reify:fsevents: sill reify mark deleted []
    1.问题描述执行安装内容:npminstallsass-D报错:reify:fsevents:sillreifymarkdeleted[]2、解决方法2.1查看当前npm镜像:npmconfiggetregistry发现是淘宝镜像https://registry.npm.taobao.org/2.2将淘宝镜像改为npm官方镜像npmconfigsetregistryhttps:......
  • SQL server配置邮件服务已报错处理
    报错处理:SQLerror'Mailnotqueued.DatabaseMailisstopped.UseSysmail_start_sptostartDatabaseMail'邮件未排队。数据库邮件已停止。使用sysmail_start_sp来启动数据库邮件。1)确认数据库邮件是否启动。执行下面sql,若显示“1”,表示已启动。sp_configure'showadvanced......
  • 从wsl复制文件到windows立刻读报错Permission denied
    因为是在windows使用IDE开发,但用到了ubuntu下抓的pcap文件,我直接从wsl把文件复制到windows目录下,使用WatchService监视目录。第一次正常,第二次以后一直报错org.pcap4j.core.PcapNativeException:E:\input_test\xxx.pcap:Permissiondenied。起初以为是其他程序也开了文件没正常......
  • Win10 添加或删除功能时报错:0x80073701,找不到引用的汇编 (ERROR_SXS_ASSEMBLY_MISSING
    问题描述:当通过控制面板或DISM命令或PowerShell命令Enable-WindowsOptionalFeature修改Windows功能时,可能会遇到此报错,导致功能修改失败。关于这个问题的来源,英文版的错误信息很明确:ERROR_SXS_ASSEMBLY_MISSING,有SXS组件找不到,中文机翻痕迹明显,压根看不懂是啥意思。如果你是......
  • Teamcenter SOA开发报错:您没有最新的时间表。请刷新时间表以获取最新副本。
    1、时间表创建任务的时候报了这个错。按字面意思,只刷新时间表是不行的。 解决方法:你创建的任务,肯定会放在一个父任务的。这是要将父任务,进行刷新。如果刷新不行的,可以尝试释放锁的刷新。如果还是不行,把时间表对象也放进来刷新。......
  • Tomcat报错Pailed to start component [StandardEngine[CatalinalStandardHost[localh
    话不多说直接上图就完了就下边这个错困扰了我一两个小时,到现在说实话我也没找到到底是什么原因,就是之前的一个版本war包还可以在tomcat上边运行但是最近更新的war包就不行就会报一个这个错,我看到网上有人说是tomcat的问题,我看其他war包都能正常使用我就没想到会是这个问题但最终的......
  • 【快应用】华为ide编译报错处理合集
    ​【关键词】Openssl 、静态检查、scoped 【问题描述1】华为ide编译报错,提示invalidopensslexitcode:3221225781%opensslgenrsa4096,该如何解决?​【解决方案】方法一:在华为ide的目录resources\app\extensions\deveco-debug\lib\OpenSSL-Win64\bin下执行./openssl.exe......