[prev in list] [next in list] [prev in thread] [next in thread] 

List:       python-distutils-sig
Subject:    [Distutils] setup.py test doesn't honor --find-links
From:       pje () telecommunity ! com (Phillip J !  Eby)
Date:       2006-03-16 19:49:36
Message-ID: 5.1.1.6.0.20060316143730.02f98cb8 () mail ! telecommunity ! com
[Download RAW message or body]

At 10:52 AM 3/16/2006 -0500, Tres Seaver wrote:
>I'm a bit lost as to the rationale for the separate metadata filee in
>that post:  why wouldn't we just use the 'dependency_links' attribute of
>the distribution?

Because the original post is discussing the scenario where you are 
installing an egg that was already built by someone else.  You're correct 
that the fetch_build_eggs() method can and should just use the attribute 
directly.


>   At any rate, I'm attaching a partially-working patch.

I'll take it for a spin.  It looks pretty good, except that easy_install 
doesn't use it.  I can go ahead and add that bit.  The doc is a bit, um, 
terse, but I can flesh it out a bit I guess.  :)


>I could get the 'dependency_links.txt' file to be created, but couldn't
>figure out how to use the pkg_resources facilities for reading it while
>inside 'fetch_build_eggs'.

You don't need to; it's the easy_install command that needs to do that, in 
process_distribution() I believe.


>   I alos ran into the problem that, since the
>'test' command doesn't support the usual 'easy_install' arguments (my
>original reason for posting), I couldn't control where the downloaded
>packages would be installed:  they went directly in my local sandbox.

That's where build dependencies are supposed to go, actually; building and 
testing a package shouldn't cause build-time dependencies to be permanently 
installed on the build system, without an explicit action.  You can always 
"easy_install *.egg" if you want to make them permanent.


>My original plan was to add the 'easy_install' command line args to
>the 'test' command, which would have allowed:
>
>     $ /path/to/python setup.py test \
>        --find-links="http://download.zope.org/distribution"
>
>Under the mechanism you redireted me to, I need to add the equivalent
>URL into zi/setup.py as a 'dependency_link' argument to 'setup', and
>then arrange for that value to be used as the 'find_links' value for
>the 'test' command.  Is that what you intended?

Yes; it should get passed to the find_links argument given to the 
easy_install command instance created by Distribution.fetch_build_eggs(), 
which is what your patch does.


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic