简体   繁体   English

curl https://pypi.python.org/simple/pip不返回任何内容

[英]curl https://pypi.python.org/simple/pip returns nothing

I have run into a very strange error on my MacBook. 我在MacBook上遇到了一个非常奇怪的错误。 I've seen some similar posts but none of them solved my issue. 我见过一些类似的帖子,但没有一个解决了我的问题。

I've been trying to install some Python libraries, and I tried to use curl to view this link: https://pypi.python.org/simple/pip/ 我一直在尝试安装一些Python库,并且尝试使用curl来查看此链接: https : //pypi.python.org/simple/pip/

It's very strange that the curl command returned nothing but a bash prompt like: curl命令只返回如下bash提示,这很奇怪:

$ curl https://pypi.python.org/simple/pip

$

At the beginning, I thought that's my proxy/firewall's problem, but when I try the link in my Safari/Chrome, the web browser displays the page perfectly. 一开始,我认为这是我的代理服务器/防火墙的问题,但是当我在Safari / Chrome浏览器中尝试链接时,网络浏览器会完美显示该页面。

What's wrong with my curl command? 我的curl命令出了什么问题? I am using curl coming alone with Mac OS El Capitan. 我正在Mac OS El Capitan中单独使用curl。

$ which curl
/usr/bin/curl

Try using curl in verbose mode to see why: 尝试在详细模式下使用curl以查看原因:

curl -v https://pypi.python.org/simple/pip

The response is a permanent redirect. 该响应是永久重定向。 It works if you append a trailing slash as follows: 如果您添加尾随斜杠,则如下所示:

curl https://pypi.python.org/simple/pip/

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 Python pip错误:“无法获取索引基URL https://pypi.python.org/simple/” - Python pip error: “Cannot fetch index base URL https://pypi.python.org/simple/” 我无法升级pip:无法获取URL https://pypi.python.org/simple/pip/:存在一个确认ssl证书的问题 - I can't upgrade pip: Could not fetch URL https://pypi.python.org/simple/pip/: There was a prόblem confirming the ssl certificate pip 连接失败:无法获取索引基 URL http://pypi.python.org/simple/ - pip connection failure: cannot fetch index base URL http://pypi.python.org/simple/ 无法获取索引库 URL https://pypi.python.org/simple/ ~ 安装后 Python 3 OS X - Cannot fetch index base URL https://pypi.python.org/simple/ ~ After Installing Python 3 OS X 无法安装Django-无法获取索引基本URL https://pypi.python.org/simple/ - Can't install Django - Cannot fetch index base URL https://pypi.python.org/simple/ 配置pip以从pypi.python.org获取丢失的软件包 - configure pip to get missing package from pypi.python.org 为什么pypi.python.org/simple上有一些软件包,但是没有页面? - Why are some packages on pypi.python.org/simple, but have no page? 当pip.conf指定其他位置时,为什么pip试图到达pypi.python.org? - Why is pip trying to reach pypi.python.org when pip.conf specifies elsewhere? 与pypi.python.org的连接超时 - Connection to pypi.python.org timed out 如何解决 ReadTimeoutError: HTTPSConnectionPool(host='pypi.python.org', port=443) with pip? - How to solve ReadTimeoutError: HTTPSConnectionPool(host='pypi.python.org', port=443) with pip?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM