为什么pip install会挂在此URL上?

时间:2014-09-24 04:56:57

标签: python python-3.x pip pypi

背景

自从我花时间编程以来已经有一段时间了,所以我决定在RaspberryPi上处理一个项目。

我正在尝试开发一个名为aosong的模块。我目前已将其发布在GithubPypi上。它有一个名为quick2wire-api, which is only hosted on Github的依赖项。

目标

最终我的目标是在我正在构建的应用程序中的pip install aosong文件中执行aosongrequirements.txt,并将其包含在`quick2wire

当前状态

因此,当我尝试进行pip安装时,这就是我得到的

(test_aosong)matt@raspberrypi:~/src/aosong$ pip install -v -v -v aosong
Downloading/unpacking aosong
  Getting page https://pypi.python.org/simple/aosong/
  URLs to search for versions for aosong:
  * https://pypi.python.org/simple/aosong/
  Analyzing links from page https://pypi.python.org/simple/aosong/
    Skipping link https://pypi.python.org/packages/3.4/a/aosong/aosong-0.0.1-py3.4.egg#md5=9af74215cbfcfed8e046a4557824ee24 (from https://pypi.python.org/simple/aosong/); unknown archive format: .egg
    Found link https://pypi.python.org/packages/source/a/aosong/aosong-0.0.1.linux-armv6l.tar.gz#md5=98a957680fd3ed729ba0a51b38b54ece (from https://pypi.python.org/simple/aosong/), version: 0.0.1.linux-armv6l
    Found link https://pypi.python.org/packages/source/a/aosong/aosong-0.0.1.tar.gz#md5=d1a76e0044472a782e72adb8e858a264 (from https://pypi.python.org/simple/aosong/), version: 0.0.1
  Ignoring link https://pypi.python.org/packages/source/a/aosong/aosong-0.0.1.linux-armv6l.tar.gz#md5=98a957680fd3ed729ba0a51b38b54ece (from https://pypi.python.org/simple/aosong/), version 0.0.1.linux-armv6l is a pre-release (use --pre to allow).
  Downloading aosong-0.0.1.tar.gz
  Downloading from URL https://pypi.python.org/packages/source/a/aosong/aosong-0.0.1.tar.gz#md5=d1a76e0044472a782e72adb8e858a264 (from https://pypi.python.org/simple/aosong/)
  Running setup.py (path:/home/matt/.pyenv/versions/test_aosong/build/aosong/setup.py) egg_info for package aosong
    Running command python setup.py egg_info
    running egg_info
    creating pip-egg-info/aosong.egg-info
    writing top-level names to pip-egg-info/aosong.egg-info/top_level.txt
    writing pip-egg-info/aosong.egg-info/PKG-INFO
    writing dependency_links to pip-egg-info/aosong.egg-info/dependency_links.txt
    writing requirements to pip-egg-info/aosong.egg-info/requires.txt
    writing manifest file 'pip-egg-info/aosong.egg-info/SOURCES.txt'
    warning: manifest_maker: standard file '-c' not found

    reading manifest file 'pip-egg-info/aosong.egg-info/SOURCES.txt'
    writing manifest file 'pip-egg-info/aosong.egg-info/SOURCES.txt'
  Source in /home/matt/.pyenv/versions/test_aosong/build/aosong has version 0.0.1, which satisfies requirement aosong
Downloading/unpacking quick2wire-api>=0.0.0.2 (from aosong)
  Getting page https://pypi.python.org/simple/quick2wire-api/
  Could not fetch URL https://pypi.python.org/simple/quick2wire-api/: 404 Client Error: Not Found
  Will skip URL https://pypi.python.org/simple/quick2wire-api/ when looking for download links for quick2wire-api>=0.0.0.2 (from aosong)
  Getting page https://pypi.python.org/simple/

10分钟后......

此时它会持续10分钟或更长时间。经过一段时间后,这是剩下的部分:

URLs to search for versions for quick2wire-api>=0.0.0.2 (from aosong):
  * https://pypi.python.org/simple/quick2wire-api/
  Getting page https://pypi.python.org/simple/quick2wire-api/
  Could not fetch URL https://pypi.python.org/simple/quick2wire-api/: 404 Client Error: Not Found
  Will skip URL https://pypi.python.org/simple/quick2wire-api/ when looking for download links for quick2wire-api>=0.0.0.2 (from aosong)
  Could not find any downloads that satisfy the requirement quick2wire-api>=0.0.0.2 (from aosong)
Cleaning up...
  Removing temporary dir /home/matt/.pyenv/versions/test_aosong/build...
No distributions at all found for quick2wire-api>=0.0.0.2 (from aosong)
Exception information:
Traceback (most recent call last):
  File "/home/matt/.pyenv/versions/test_aosong/lib/python3.4/site-packages/pip/basecommand.py", line 122, in main
    status = self.run(options, args)
  File "/home/matt/.pyenv/versions/test_aosong/lib/python3.4/site-packages/pip/commands/install.py", line 278, in run
    requirement_set.prepare_files(finder, force_root_egg_info=self.bundle, bundle=self.bundle)
  File "/home/matt/.pyenv/versions/test_aosong/lib/python3.4/site-packages/pip/req.py", line 1177, in prepare_files
    url = finder.find_requirement(req_to_install, upgrade=self.upgrade)
  File "/home/matt/.pyenv/versions/test_aosong/lib/python3.4/site-packages/pip/index.py", line 277, in find_requirement
    raise DistributionNotFound('No distributions at all found for %s' % req)
pip.exceptions.DistributionNotFound: No distributions at all found for quick2wire-api>=0.0.0.2 (from aosong)

更多背景

本地

如果我从pip install -r requirements.txt模块的根目录安装asong,则安装工作正常。

此外,如果我通过设置工具安装,ala python setup.py install它也能完美运行。

环境

(test_aosong)matt@raspberrypi:~/src/aosong$ uname -a
Linux raspberrypi 3.12.28+ #709 PREEMPT Mon Sep 8 15:28:00 BST 2014 armv6l GNU/Linux
(test_aosong)matt@raspberrypi:~/src/aosong$ pip list
pip (1.5.6)
pkginfo (1.1)
requests (2.4.1)
setuptools (3.6)
twine (1.3.1)
(test_aosong)matt@raspberrypi:~/src/aosong$ pyenv virtualenvs
  am2315 (created from /home/matt/.pyenv/versions/3.4.1)
* test_aosong (created from /home/matt/.pyenv/versions/3.4.1)
(test_aosong)matt@raspberrypi:~/src/aosong$ pyenv which python
/home/matt/.pyenv/versions/test_aosong/bin/python
(test_aosong)matt@raspberrypi:~/src/aosong$

问题

有人可以帮我理解为什么pip install aosong没有安装quick2wire-api1依赖项吗?

1 个答案:

答案 0 :(得分:0)

pip install --process-dependency-links aosong