问题描述
Collecting rsa==3.1.1 (from -r /racetrack/.requirements.txt (line 41))
eval (python -m virtualfish)
Downloading rsa-3.1.1.tar.gz
Complete output from command python setup.py egg_info:
Downloading http://pypi.python.org/packages/source/d/distribute/distribute-0.6.10.tar.gz
Traceback (most recent call last):
File "/usr/lib/python2.7/urllib2.py", line 558, in http_error_default
raise HTTPError(req.get_full_url(), code, msg, hdrs, fp)
urllib2.HTTPError: HTTP Error 403: SSL is required
推荐答案
解决方案:升级到库的最新版本.
一切都从这里开始,突然(2017年10月),Distutils团队决定撤销对非https请求的支持,而不必担心破坏众多python库早期版本的向后兼容性.有点不专业,但是嘿,这是Python世界.
It all starts here, suddenly(on Oct-2017) the Distutils team decided to revoke support for non-https requests without worrying about breaking the backward compatibility of earlier versions of numerous python libraries. Bit unprofessional, but hey it's Python world.
这就是解决方法,只需在任何库(nltk==3.2.5
等)上转到库的最新版本(在我的情况下为rsa==3.4.2
)
So here is the fix, Simply move on to the latest version of the library (rsa==3.4.2
in my case) on whatever library (nltk==3.2.5
etc)
替代解决方案:分叉(或本地复制)repo&将http
网址修改为https
Alternate Solution: Fork(or locally copy) the version of repo & modify the http
url into https
不过,请注意在维护另一个项目时是否正在执行此操作,因为要升级的依赖项可能与作者原先打算的原始库不兼容,例如,在我的上下文中,rsa
在另一个库下用作依赖性.因此,解决方案是升级父库,以便自动解决此问题.
Nonetheless, watch out if you are doing this while maintaining another project since the dependency you are upgrading might not be compatible with the original library the author had intended, for example in my context rsa
was used under another library as a dependency. Thus the solution was to upgrade the parent library so that this issue is automatically taken care.
这篇关于点安装失败:需要SSL的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!