pip install dependency-links

Ich bin mit python version 2.7 und pip version is 1.5.6.

Ich installieren möchten, zusätzliche Bibliotheken von url, wie ein git-repo auf setup.py installiert wird.

Ich wurde, extras in install_requires parameter in setup.py. Das bedeutet, meine Bibliothek erfordert zusätzliche Bibliotheken und Sie müssen auch installiert werden.

...
install_requires=[
    "Django",
    ....
],
...

Aber urls wie git-repos sind nicht gültige Zeichenfolge in install_requires im setup.py. Gehe davon aus, dass ich installieren möchte eine Bibliothek von github. Ich habe gesucht über dieses Thema und ich habe etwas gefunden, was ich kann-Bibliotheken, so dass in dependency_links im setup.py. Aber das funktioniert immer noch nicht. Hier ist meine Abhängigkeit links definition;

dependency_links=[
    "https://github.com/.../tarball/master/#egg=1.0.0",
    "https://github.com/.../tarball/master#egg=0.9.3",
], 

Die links gültig sind. Ich kann Sie herunterladen, von einem internet-browser mit diesen urls. Diese zusätzlichen Bibliotheken noch nicht installiert ist, mit meiner Einstellung. Ich habe auch versucht --process-dependency-links parameter erzwingen pip. Aber das Ergebnis ist dasselbe. Ich nehme kein Fehler, wenn pipping.

Nach der installation sehe ich keine Bibliothek in pip freeze Ergebnis in dependency_links.

Wie kann ich Sie heruntergeladen werden, mit meinem setup.py installation?

Bearbeitet:

Hier ist meine komplette setup.py

from setuptools import setup

try:
    long_description = open('README.md').read()
except IOError:
    long_description = ''

setup(
    name='esef-sso',
    version='1.0.0.0',
    description='',
    url='https://github.com/egemsoft/esef-sso.git',
    keywords=["django", "egemsoft", "sso", "esefsso"],
    install_requires=[
        "Django",
        "webservices",
        "requests",
        "esef-auth==1.0.0.0",
        "django-simple-sso==0.9.3"
    ],
    dependency_links=[
        "https://github.com/egemsoft/esef-auth/tarball/master/#egg=1.0.0.0",
        "https://github.com/egemsoft/django-simple-sso/tarball/master#egg=0.9.3",
    ],

    packages=[
        'esef_sso_client',
        'esef_sso_client.models',
        'esef_sso_server',
        'esef_sso_server.models',
    ],
    include_package_data=True,
    zip_safe=False,
    platforms=['any'],
)

Bearbeitet 2:

Hier ist pip melden;

Downloading/unpacking esef-auth==1.0.0.0 (from esef-sso==1.0.0.0)
  Getting page https://pypi.python.org/simple/esef-auth/
  Could not fetch URL https://pypi.python.org/simple/esef-auth/: 404 Client Error: Not Found
  Will skip URL https://pypi.python.org/simple/esef-auth/ when looking for download links for esef-auth==1.0.0.0 (from esef-sso==1.0.0.0)
  Getting page https://pypi.python.org/simple/
  URLs to search for versions for esef-auth==1.0.0.0 (from esef-sso==1.0.0.0):
  * https://pypi.python.org/simple/esef-auth/1.0.0.0
  * https://pypi.python.org/simple/esef-auth/
  Getting page https://pypi.python.org/simple/esef-auth/1.0.0.0
  Could not fetch URL https://pypi.python.org/simple/esef-auth/1.0.0.0: 404 Client Error: Not Found
  Will skip URL https://pypi.python.org/simple/esef-auth/1.0.0.0 when looking for download links for esef-auth==1.0.0.0 (from esef-sso==1.0.0.0)
  Getting page https://pypi.python.org/simple/esef-auth/
  Could not fetch URL https://pypi.python.org/simple/esef-auth/: 404 Client Error: Not Found
  Will skip URL https://pypi.python.org/simple/esef-auth/ when looking for download links for esef-auth==1.0.0.0 (from esef-sso==1.0.0.0)
  Could not find any downloads that satisfy the requirement esef-auth==1.0.0.0 (from esef-sso==1.0.0.0)
Cleaning up...
  Removing temporary dir /Users/ahmetdal/.virtualenvs/esef-sso-example/build...
No distributions at all found for esef-auth==1.0.0.0 (from esef-sso==1.0.0.0)
Exception information:
Traceback (most recent call last):
  File "/Users/ahmetdal/.virtualenvs/esef-sso-example/lib/python2.7/site-packages/pip/basecommand.py", line 122, in main
    status = self.run(options, args)
  File "/Users/ahmetdal/.virtualenvs/esef-sso-example/lib/python2.7/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 "/Users/ahmetdal/.virtualenvs/esef-sso-example/lib/python2.7/site-packages/pip/req.py", line 1177, in prepare_files
    url = finder.find_requirement(req_to_install, upgrade=self.upgrade)
  File "/Users/ahmetdal/.virtualenvs/esef-sso-example/lib/python2.7/site-packages/pip/index.py", line 277, in find_requirement
    raise DistributionNotFound('No distributions at all found for %s' % req)
DistributionNotFound: No distributions at all found for esef-auth==1.0.0.0 (from esef-sso==1.0.0.0)

Scheint es, es nicht die Quellen in dependency_links.

InformationsquelleAutor Ahmet DAL | 2014-09-26

Schreibe einen Kommentar