点差安装超时问题

时间:2018-05-12 10:13:43

标签: python-2.7 pandas pip

我正在尝试在公司电脑上安装pandas。 我试着做



pip install pandas




但是操作重试然后超时。

然后我下载了包裹:

大熊猫-0.22.0-cp27-cp27m-win_amd64.whl

并安装:



pip install pandas-0.22.0-cp27-cp27m-win_amd64




但是我收到以下错误:



Retrying (Retry(total=4, connect=None, read=None, redirect=None, status=None)) after connection broken by 'ConnectTimeoutError(<pip._vendor.urllib3.connection.VerifiedHTTPSConnection object at 0x0000000003F16320>, 'Connection to pypi.python.org timed out. (connect timeout=15)')': /simple/pytz/
  Retrying (Retry(total=3, connect=None, read=None, redirect=None, status=None)) after connection broken by 'ConnectTimeoutError(<pip._vendor.urllib3.connection.VerifiedHTTPSConnection object at 0x0000000003F16C50>, 'Connection to pypi.python.org timed out. (connect timeout=15)')': /simple/pytz/
  Retrying (Retry(total=2, connect=None, read=None, redirect=None, status=None)) after connection broken by 'ConnectTimeoutError(<pip._vendor.urllib3.connection.VerifiedHTTPSConnection object at 0x0000000003F16C18>, 'Connection to pypi.python.org timed out. (connect timeout=15)')': /simple/pytz/
  Retrying (Retry(total=1, connect=None, read=None, redirect=None, status=None)) after connection broken by 'ConnectTimeoutError(<pip._vendor.urllib3.connection.VerifiedHTTPSConnection object at 0x0000000003F16780>, 'Connection to pypi.python.org timed out. (connect timeout=15)')': /simple/pytz/
  Retrying (Retry(total=0, connect=None, read=None, redirect=None, status=None)) after connection broken by 'ConnectTimeoutError(<pip._vendor.urllib3.connection.VerifiedHTTPSConnection object at 0x0000000003F16898>, 'Connection to pypi.python.org timed out. (connect timeout=15)')': /simple/pytz/
  Could not find a version that satisfies the requirement pytz>=2011k (from pandas==0.22.0) (from versions: )
No matching distribution found for pytz>=2011k (from pandas==0.22.0)
&#13;
&#13;
&#13;

我对包裹做了同样的事:pandas-0.22.0-cp27-cp27m-win_amd64.whl

我也尝试使用代理:

pip --proxy=IND\namit.kewat:xl123456@192.168.180.150:8880 install numpy

但是我无法得到大熊猫。

当我尝试访问该网站时:https://pypi.org/project/pandas/#files我可以在资源管理器上无任何问题地访问它

4 个答案:

答案 0 :(得分:15)

就我而言,我的网络默认配置为使用 IPV6,因此我将其更改为仅使用 IPV4。

您可以在控制面板的“网络连接”部分执行此操作:

'Control Panel\All Control Panel Items\Network Connections'

enter image description here

比禁用 IPV6 选项:

enter image description here

答案 1 :(得分:9)

PIP的默认超时时间为15 secreference guidePandas是一个相对较大的文件,大小为10MB,并且依赖于Numpy,仍然需要20MB(如果尚未安装)。此外,您的网络连接可能很慢。因此,将PIP设置为更长的时间,例如,将其设置为1000 sec

pip --default-timeout=1000 install pandas

如@Pouya Khalilzad所建议。

答案 2 :(得分:3)

这对我有用:

pip --default-timeout=1000 install pandas

答案 3 :(得分:1)

你用anaconda安装了python吗?如果不是,我建议您使用anaconda重新安装。

如果您使用anaconda安装python,请尝试此conda install pandas