我通过以下命令安装了弹性搜索策展人。
sudo pip install -U elasticsearch-curator
一切都安装好了。
但是现在当我执行以下操作
curator_cli --version
我收到以下依赖项警告。
/usr/local/lib/python2.7/dist-packages/requests/__init__.py:83: RequestsDependencyWarning: Old version of cryptography ([1, 2, 3]) may cause slowdown.
warnings.warn(warning, RequestsDependencyWarning)
curator_cli, version 5.5.4
如何解决警告或隐藏警告?
答案 0 :(得分:64)
所以我花了两件事才能使它正常工作。
首先,我根据Mufeeds的建议升级了密码系统
sudo pip install --upgrade cryptography
这每次给我pip <any command>
Traceback (most recent call last):
File "/usr/local/bin/pip", line 7, in <module>
from pip._internal import main
File "/usr/local/lib/python2.7/dist-packages/pip/_internal/__init__.py", line 42, in <module>
from pip._internal import cmdoptions
File "/usr/local/lib/python2.7/dist-packages/pip/_internal/cmdoptions.py", line 16, in <module>
from pip._internal.index import (
File "/usr/local/lib/python2.7/dist-packages/pip/_internal/index.py", line 15, in <module>
from pip._vendor import html5lib, requests, six
File "/usr/local/lib/python2.7/dist-packages/pip/_vendor/requests/__init__.py", line 86, in <module>
from pip._vendor.urllib3.contrib import pyopenssl
File "/usr/local/lib/python2.7/dist-packages/pip/_vendor/urllib3/contrib/pyopenssl.py", line 46, in <module>
import OpenSSL.SSL
File "/usr/lib/python2.7/dist-packages/OpenSSL/__init__.py", line 8, in <module>
from OpenSSL import rand, crypto, SSL
File "/usr/lib/python2.7/dist-packages/OpenSSL/SSL.py", line 118, in <module>
SSL_ST_INIT = _lib.SSL_ST_INIT
AttributeError: 'module' object has no attribute 'SSL_ST_INIT'
通过对PyOpenSSL进行加密解决了此问题
sudo python -m easy_install --upgrade pyOpenSSL
Curator现在可以按预期运行,没有警告
curator_cli --version
> curator_cli, version 5.5.4
答案 1 :(得分:0)
下面的第一步将更新密码,但会破坏pyopenssl。
sudo pip install --upgrade cryptography
我们可以通过删除pyopennssl库并使用pip重新安装来解决此问题。
sudo rm -rf /usr/lib/python2.7/dist-packages/OpenSSL
sudo rm -rf /usr/lib/python2.7/dist-packages/pyOpenSSL-0.15.1.egg-info
sudo pip install pyopenssl --upgrade
sudo pip install cryptography --upgrade
如果打开的sll库仍然被破坏,最后一行将产生错误,因此这将验证所有内容都应该很好...
我的喜好是避免像混合安装一样易于安装的其他软件包管理,因此,在其他人也都喜欢的情况下共享它。