Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/python/350.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Python Pip错误-找不到满足junos eznc要求的版本_Python_Ssl_Pip_Junos Automation - Fatal编程技术网

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

Python Pip错误-找不到满足junos eznc要求的版本,python,ssl,pip,junos-automation,Python,Ssl,Pip,Junos Automation,Ansible需要Python junos eznc模块: junos eznc>=1.2.2是必需的,但似乎未安装 可以使用pip安装junos eznc安装它 但是,在运行sudo pip install junos eznc时,我得到以下信息: Collecting junos-eznc /usr/lib/python2.6/site-packages/pip/_vendor/requests/packages/urllib3/connection.py:279: SystemTimeWa

Ansible需要Python junos eznc模块:

junos eznc>=1.2.2是必需的,但似乎未安装

可以使用pip安装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
谁能给我指出正确的方向吗

我确实发现了这篇文章:

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

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

您收到的警告消息是:

2014年1月1日之前的系统时间已经过了很久。这可能会导致SSL验证错误

您确实会遇到SSL验证错误:

证书验证失败

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

您还收到两条警告,建议升级Python,这两条警告可能不重要:

您可以升级到较新版本的Python来解决此问题


解决方案:升级Python。

能否将“openssl s_client-showcerts-connect pypi.Python.org:443”的输出粘贴到某个地方?您向错误的受众提出了错误的问题。它与Ansible无关-您没有安装所需的Python模块,因此在未安装模块时会抛出一个错误-它没有任何问题。您真正的问题是,由于您发布的错误消息中给出的原因,您的pip Python包管理器无法验证SSL证书。您的设备似乎被置于防火墙或某个代理之下,无法访问pypi.Python.org下载包。你能检查curl-Is的输出吗https://pypi.python.org/simple/pip/I 确实更改了日期,这似乎停止了错误-然后pip尝试安装正在收集的pycparser>>>>>>>>>>>>然后盒子就死掉了!我再也无法访问它了:有什么想法吗?为什么?