python - Pip 错误 - 找不到满足 junos-eznc 要求的版本

标签 python ssl pip junos-automation

Ansible 需要 Python junos-eznc 模块:

junos-eznc >= 1.2.2 is required but does not appear to be installed.

It can be installed using pip install junos-eznc

但是,当运行 sudo pip install junos-eznc - 我得到这个:

Collecting junos-eznc
/usr/lib/python2.6/site-packages/pip/_vendor/requests/packages/urllib3/connection.py:279: SystemTimeWarning: System time is way off (before 2014-01-01). This will probably lead to SSL verification errors
  SystemTimeWarning
/usr/lib/python2.6/site-packages/pip/_vendor/requests/packages/urllib3/util/ssl_.py:318: SNIMissingWarning: An HTTPS request has been made, but the SNI (Subject Name Indication) extension to TLS is not available on this platform. This may cause the server to present an incorrect TLS certificate, which can cause validation failures. You can upgrade to a newer version of Python to solve this. For more information, see https://urllib3.readthedocs.org/en/latest/security.html#snimissingwarning.
  SNIMissingWarning
/usr/lib/python2.6/site-packages/pip/_vendor/requests/packages/urllib3/util/ssl_.py:122: InsecurePlatformWarning: A true SSLContext object is not available. This prevents urllib3 from configuring SSL appropriately and may cause certain SSL connections to fail. You can upgrade to a newer version of Python to solve this. For more information, see https://urllib3.readthedocs.org/en/latest/security.html#insecureplatformwarning.
  InsecurePlatformWarning
  Could not fetch URL https://pypi.python.org/simple/junos-eznc/: There was a problem confirming the ssl certificate: [Errno 1] _ssl.c:492: error:14090086:SSL routines:SSL3_GET_SERVER_CERTIFICATE:certificate verify failed - skipping
  Could not find a version that satisfies the requirement junos-eznc (from versions: )
No matching distribution found for junos-eznc

谁能指出我正确的方向?


我确实找到了这篇文章:https://github.com/Homebrew/legacy-homebrew/issues/41253

我尝试重命名我的文件,但仍然没有成功:

]$ls
ca-bundle999.crt  ca-bundle999.trust.crt  ca-bundle.jks  exim.pem  localhost.crt  make-dummy-cert  Makefile  renew-dummy-cert

最佳答案

您收到的警告消息是:

System time is way off (before 2014-01-01). This will probably lead to SSL verification errors

而且您确实遇到了 SSL 验证错误:

certificate verify failed

解决方案:将系统日期更改为当前日期。


您还会收到两个警告(可能不严重),并建议升级您的 Python:

You can upgrade to a newer version of Python to solve this.

解决方案:升级 Python。

关于python - Pip 错误 - 找不到满足 junos-eznc 要求的版本,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/43127536/

相关文章:

python - 如何在不使用 * 运算符(或/运算符)的情况下递归地将两个正整数相乘? .您可以使用加法、减法和位移

python-3.x - pip - 安装特定的软件包版本不起作用

python - 提高 Python + numpy 数组分配/初始化性能

python - 在Python中使用正则表达式替换多个项目

email - Plesk 发送电子邮件 TLS 不可用

python-3.x - python-gitlab api SSL 握手错误 : Error([ ('SSL routines' , 'ssl3_get_server_certificate' , 'certificate verify failed' )],

ssl - javax.net.ssl.keystore 与 javax.net.ssl.keyStore 相同或不同

python - pip 如何决定使用哪个 linux wheel?

python - 以编程方式检查是否满足 Python 依赖项

python正则表达式获取电子邮件地址的第一部分