为了账号安全,请及时绑定邮箱和手机立即绑定

pip install pyOpenSSL后pip故障

pip install pyOpenSSL后pip故障

吃鸡游戏 2019-02-19 12:00:36
问题描述 pip install pyOpenSSL==16.0.0后pip故障(pip install pyOpenSSL正常)pip -V或pip list会报错pip uninstall pyOpenSSL也会报错 报错内容都是下面内容: Traceback (most recent call last): File "/usr/bin/pip", line 7, in <module> from pip._internal import main File "/usr/lib/python2.7/site-packages/pip/_internal/__init__.py", line 42, in <module> from pip._internal import cmdoptions File "/usr/lib/python2.7/site-packages/pip/_internal/cmdoptions.py", line 16, in <module> from pip._internal.index import ( File "/usr/lib/python2.7/site-packages/pip/_internal/index.py", line 14, in <module> from pip._vendor import html5lib, requests, six File "/usr/lib/python2.7/site-packages/pip/_vendor/requests/__init__.py", line 97, in <module> from pip._vendor.urllib3.contrib import pyopenssl File "/usr/lib/python2.7/site-packages/pip/_vendor/urllib3/contrib/pyopenssl.py", line 46, in <module> import OpenSSL.SSL File "/usr/lib/python2.7/site-packages/OpenSSL/__init__.py", line 8, in <module> from OpenSSL import rand, crypto, SSL File "/usr/lib/python2.7/site-packages/OpenSSL/SSL.py", line 124, in <module> SSL_ST_INIT = _lib.SSL_ST_INIT AttributeError: 'module' object has no attribute 'SSL_ST_INIT' 问题出现的平台版本 Linux web 3.10.0-693.2.2.el7.x86_64 #1 SMP Tue Sep 12 22:26:13 UTC 2017 x86_64 x86_64 x86_64 GNU/Linuxpip 18.0 from /usr/lib/python2.7/site-packages/pip (python 2.7)
查看完整描述

1 回答

?
潇潇雨雨

TA贡献1833条经验 获得超4个赞

16.2.0+ 版本貌似修复了这个issue。先清除掉已安装的package再试一下pip install pyOpenSSL==16.2.0

查看完整回答
反对 回复 2019-03-01
  • 1 回答
  • 0 关注
  • 1474 浏览
慕课专栏
更多

添加回答

举报

0/150
提交
取消
意见反馈 帮助中心 APP下载
官方微信