pip安装模块警告InsecurePlatformWarning: A true SSLContext object is not available.

在用pip7.1.2版本安装第三方模块时出现了如下警告:

/usr/lib/python2.7/site-packages/pip-7.1.2-py2.7.egg/pip/_vendor/requests/packages/urllib3/util/ssl_.py:90: 
InsecurePlatformWarning: A true SSLContext object is not available. 
This prevents urllib3 from configuring SSL appropriatelyand may 
cause certain SSL connections to fail. For more information, see 
https://urllib3.readthedocs.org/en/latest/security.html#insecureplatformwarning.

提示是由于urllib3的SSL连接失败


解决方法

首先安装Python-devel libffi-devel openssl-devel

yum install python-devel libffi-devel openssl-devel

之后在安装pyopenssl ndg-httpsclient pyasn1

pip install pyopenssl ndg-httpsclient pyasn1

上面的包与模块安装后,就不会出现上面的告警了。

时间: 2024-07-31 20:13:49

pip安装模块警告InsecurePlatformWarning: A true SSLContext object is not available.的相关文章

禁止requests请求https的提示InsecurePlatformWarning: A true SSLContext object is not available. This prevents urllib3 from configuring SSL appropriately and may cause certain SSL connections to fail. For more

提示这个 InsecurePlatformWarning: A true SSLContext object is not available. This prevents urllib3 from configuring SSL appropriately and may cause certain SSL connections to fail. For more information, see  可以禁止提示. 方法一: requests.packages.urllib3.disable

pip 安装模块时报错问题解决方案

之前遇到pip 安装模块的时候遇到如下报错:pip._vendor.urllib3.exceptions.ReadTimeoutError: HTTPSConnectionPool(host=‘files.pythonhosted.org’, port=443): Read timed out. 试过好几种方法都不可用,方法如下: modle(对应的是软件包模块的名称) 1.设置超时时间, pip --default-timeout=100 install -U modle 2.国外镜像通常比较

pip安装pillow——死循环:[WinError5] & [TypeError:'module' object is not callable]

1.这次本来要安装个pillow,记得以前装了的,怎么这次就不行了.然后,下意识的使用:pip3 install pillow. 发现报错: [TypeError:'module' object is not callable] 2.不明就里,百度一下,解决方案:在pip升级的时候,使用--user来安装会搞定.经验人告诉你:FP 3.成功安装user版本.心里很爽.暗暗觉得: 牛逼-lity.然而:打脸. 4.这下完了.各种pip均不能使用了,甚至报[WinError5]错误.内心一片死寂,还

如何使用python的pip安装模块(还未安装成功Wordcloud的同学可参考)

1.设置python的pip.exe的path: 2.打开cmd,输入指令安装你想要的模块: 一般指令:pip install {模块名} 然后小黑框就会自动下载安装.但是大多数情况下,安装会中断.报错.出一大堆错误信息,这是因为黑框自动下载的资源在国外,直接下载容易连接中断导致出错,至少也是网速慢成乌龟. 3.因此,大力推荐使用阿里爸爸的镜像: 阿里爸爸的镜像真的超快,当然你也可以用下面列的别的镜像使用阿里爸爸镜像下载的指令如下: pip install {模块名} -i http://mir

利用pip安装模块(以安装pyperclip为例)

>任务:利用pip安装pyperclip模块 >前提:你已经在你的电脑里面安装啦Python2.7的Windows版本,并且已经配置了环境变量 >实现步骤 >>打开你的Python2.7安装文件夹,里面有一个scripts文件 >>注意:在DOS窗口中只有在Python安装路径中的scripts目录下执行pip才会弹出相应的pip信息 >>在DOS窗口中cd到Python安装路径中的scripts目录 >>运行 pip install py

windows下使用pip安装模块发生“failed with error code 1”的解决方法

win不愧是最烂的开发平台,在安装第三方模块时经常出现些幺蛾子. 今天在window中使用python3自带的pip安装scrapy时,出错,错误代码如下: Command "f:\python\python36\python.exe -u -c "import setuptools, tokenize;__file__='C:\\Users\\WONDER~1\\AppData\\Local\\Temp\\pip-build-90gvzc6m\\Twisted\\setup.py';

ubuntu下pip安装模块到正确位置

ubuntu下用pip安装软件包后ipython里面说没有 先用 pip show tensorflow 查看应该在哪个位置,这里不一定是tensorflow,可以是其他在ipython下可以用的模块 然后 sudo -H pip install --target=directory package_name 安装到正确的目录下面 原文地址:https://www.cnblogs.com/zhanchao/p/9021558.html

python的pip安装模块报编码错误

在使用python的pip安装的时候出现了这个错误 UnicodeDecodeError: 'ascii' code can't decode byte 0xef in position 7: ordinal not in range(128) 解决方案是: 在Python\Lib\site-packages 建一个文件:sitecustomize.py import sys  sys.setdefaultencoding('gbk') sys.setdefaultencoding是python

当利用pip安装模块出现错误时咋办

>在DOS窗口中到Python安装路径的scripts中执行  pip install pyperclip 出现错误 >>错误提示:Fatal error in launcher: Unable to create process using '"' >解决办法 >>在DOS根目录中执行: python3 -m pip install pyperclip