簡體   English   中英

在 Windows 上的 python 2.7.8 上安裝 pip

[英]installing pip on python 2.7.8 on windows

我正在嘗試為 python 2.7.8 安裝模塊 pip,這是 arcGIS 為您安裝的。

我正在使用安裝 pip 的引導程序方法,當我使用命令提示符運行get-pip.py時遇到錯誤。

我收到以下錯誤:

Warning (from warnings module):   File
"c:\users\vlaw\appdata\local\temp\tmpzamnrk\pip.zip\pip\_vendor\requests\packages\urllib3\util\ssl_.py",
line 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.io/en/latest/security.html#insecureplatformwarning.
Could not fetch URL https://pypi.python.org/simple/pip/: There was a
problem confirming the ssl certificate: [Errno 1] _ssl.c:510:
error:14090086:SSL routines:SSL3_GET_SERVER_CERTIFICATE:certificate
verify failed - skipping Requirement already up-to-date: pip in
c:\esripyfldr\arcgis10.3 Collecting setuptools

Warning (from warnings module):   File
"c:\users\vlaw\appdata\local\temp\tmpzamnrk\pip.zip\pip\_vendor\requests\packages\urllib3\util\ssl_.py",
line 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.io/en/latest/security.html#insecureplatformwarning.
Could not fetch URL https://pypi.python.org/simple/setuptools/: There
was a problem confirming the ssl certificate: [Errno 1] _ssl.c:510:
error:14090086:SSL routines:SSL3_GET_SERVER_CERTIFICATE:certificate
verify failed - skipping [31m  Could not find a version that
satisfies the requirement setuptools (from versions: )

我正在使用我公司提供的互聯網。 你認為防火牆是它給我錯誤的原因嗎?

您必須在防火牆內部設置代理並從防火牆外部安裝文件。

Ubuntu

export http_proxy="http://<<username>>:<<password>>@<<proxy server>>:<<proxy_port>>"
export https_proxy="https://<<username>>:<<password>>@<<proxy server>>:<<proxy_port>>"

窗戶

set HTTP_PROXY=http://<<username>>:<<password>>@<<proxy server>>:<<proxy_port>>
set HTTPS_PROXY=https://<<username>>:<<password>>@<<proxy server>>:<<proxy_port>>

我認為你應該先下載get-pip.py然后運行python get-pip.py

如果這不起作用,請使用python get-pip.py --prefix=/usr/local/

希望這會有所幫助。

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM