【问题标题】:How do I pip install from Google Code?如何从 Google 代码中进行 pip 安装?
【发布时间】:2012-09-26 19:53:56
【问题描述】:

我正在尝试安装托管在 Google Code here 上的 Gevent 测试版,但我似乎无法正确执行命令(我不断收到 无法检测存档格式 错误)。从谷歌代码 pip install gevent-1.0b4 的命令是什么?

这里是命令和错误:

(venv)zak$ pip install https://code.google.com/p/gevent/gevent-1.0b4.tar.gz Downloading/unpacking https://code.google.com/p/gevent/gevent-1.0b4.tar.gz HTTP error 404 while getting https://code.google.com/p/gevent/gevent-1.0b4.tar.gz Could not install requirement https://code.google.com/p/gevent/gevent-1.0b4.tar.gz because of error HTTP Error 404: Not Found Could not install requirement https://code.google.com/p/gevent/gevent-1.0b4.tar.gz because of HTTP error HTTP Error 404: Not Found for URL https://code.google.com/p/gevent/gevent-1.0b4.tar.gz

【问题讨论】:

  • pip install http://gevent.googlecode.com/files/gevent-1.0b4.tar.gz 对我来说很好用。
  • code.google.com/p/gevent/gevent-1.0b4.tar.gz 给出 404。你是如何构建这个 URL 的?
  • 从 Google 代码中复制粘贴。
  • 我不这么认为,下载列表页面上找不到那个链接。

标签: python repository pip google-code


【解决方案1】:

您的网址错误,它返回 404(您可以通过在浏览器中访问它来验证)。

pip install http://gevent.googlecode.com/files/gevent-1.0b4.tar.gz

会起作用的。但正如谷歌代码项目主页上所说,gevent 现在位于github

原来如此

pip install https://github.com/downloads/SiteSupport/gevent/gevent-1.0b4.tar.gz

【讨论】:

  • 我会改为使用pip install git+git://github.com/SiteSupport/gevent.git@1.0b4#egg=gevent,您可以轻松更改@ 以指向存储库中的任何提交,而不仅仅是标记发布
【解决方案2】:

试试pip install http://gevent.googlecode.com/files/gevent-1.0b4.tar.gz

【讨论】:

    猜你喜欢
    • 2019-07-12
    • 2019-06-17
    • 2017-11-23
    • 2015-08-04
    • 2020-02-12
    • 2021-12-16
    • 1970-01-01
    • 1970-01-01
    • 2020-05-14
    相关资源
    最近更新 更多