[Distutils] Building an egg from Subversion using zc.buildout

Phillip J. Eby pje at telecommunity.com
Mon Feb 12 01:05:44 CET 2007


At 01:01 PM 2/11/2007 -0500, Jim Fulton wrote:
>On Feb 10, 2007, at 7:44 PM, Phillip J. Eby wrote:
>>At 02:20 PM 2/10/2007 -0500, Jim Fulton wrote:
>>>On Feb 10, 2007, at 2:16 PM, Phillip J. Eby wrote:
>>>>At 12:54 PM 2/10/2007 -0500, Jim Fulton wrote:
>>>...
>>>
>>>>>(Note: Buildout uses PackageIndex to locate and fetch
>>>>>distributions.
>>>>>It then installs distributions itself.  if the distribution is
>>>>>already an egg,  then this is straightforward.  Otherwise, buildout
>>>>>invokes easy_install to do the installation.  It can't get a return
>>>>>value from easy_install, so it uses an Environment to find the egg
>>>>>that easy_install created.)
>>>>
>>>>Note that easy_install can be told to --record what files it
>>>>installs, so you could build a WorkingSet or Environment from that
>>>>list.
>>>
>>>I looked at that a while back.  I don't remember why I didn't take
>>>that approach.
>>>
>>>At this point, I think it would be easier to special-case ==dev. :)
>>
>>Ah, but setuptools has a ==dev06, and I think other people have
>>used other tags to denote various SVN branches.  The name used to
>>denote the version is incidental, IOW, so that way lies N special
>>cases, all different.  :)
>
>I really don't understand this feature.

That's because there is no feature, at least not the way you're thinking 
about it.

Marking a link with "#egg=projname-version" simply indicates that 
easy_install should consider that link to be for that project and version, 
regardless of what the link appears to be pointing to.

Using a version of "dev" to denote a subversion repository link is 
therefore merely a *convention*, not a feature; it has NO special handling 
in easy_install.

Meanwhile, the use of two versions in a requirement string (so that a 
subversion link tagged "dev" would be accepted for download, and the 
installed version would appear to meet the requirement) was a hack invented 
by a user, not me.  :)

And that hack, along with all the other behavior being seen, is merely an 
emergent property of the fact that you can label links, and easy_install's 
normal link-seeking behavior.



More information about the Distutils-SIG mailing list