简体   繁体   中英

How-to configure svn dependency link in setuptools

I have a setup.py file:

from setuptools import setup

setup(name='MyCartridge',
      version='1.0',
      description='My Cartridge',
      author='First Last',
      author_email='info@example.com',
      url='http://www.example.com/',
      install_requires=[
                        'CustomFieldAdminPlugin-0.2.8-r13289'
      ],
      dependency_links = [
                        'http://trac-hacks.org/svn/customfieldadminplugin/0.11#egg=CustomFieldAdminPlugin-0.2.8-r13289'
      ],
     )

When I run it, setuptools fails to checkout sources with error:

Can't download http://trac-hacks.org/svn/customfieldadminplugin/0.11#egg=CustomFieldAdminPlugin-0.2.8-r13289: 400 Bad Request

I tried to use svn+http , 0.11#egg , 0.11/#egg , 0.11@13289#egg , 0.11?p=13289#egg and it still fails to checkout.

What I did wrong?

According to documentation: http://pythonhosted.org/setuptools/setuptools.html#dependencies-that-aren-t-in-pypi

you should use svn+URL for Subversion or as a more complete version vcs+proto://host/path@revision#egg=project-version

So you should try svn+http://trac-hacks.org/svn/customfieldadminplugin/0.11 @13289#egg=CustomFieldAdminPlugin-0.2.8-r13289

Works for me btw.

It was discovered that by default there was setuptools-0.6 installed at the server. After upgrading to setuptools-2.1 the problem gone.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM