[Distutils] [buildout] improving zc.recipe.egg's README.txt

Philipp von Weitershausen philipp at weitershausen.de
Thu Aug 14 13:14:34 CEST 2008

Chris Withers wrote:
> Jim Fulton wrote:
>>> However, given that the demo egg is a binary egg, I can't decide what 
>>> the best way to do this is.
>> We could just show the contents of setup.py or simply explain, perhaps 
>> in a footnote that the scripts are defined via entry points, giving a 
>> link to the setuptools documentation.
> To be honest, given the use of the demo egg all over the place, maybe 
> it'd be better just to have it as a static directory in the distribution?
> Is there any technical reason that means we can't do this?
>>> I'd thought of using the zipfile module to reach inside the egg, but 
>>> I'm confused as to why -py2.3.egg files are specified in the test and 
>>> work even though I'm running with python 2.4 and there's no python 
>>> 2.3 in sight?
>> The examples have to show something, The tests have to be run with 
>> multiple versions of Python, since multiple versions of Python are 
>> supported.  An output normalizer takes care adjusting actual and 
>> expected output for the version of Python used at run time.
> Okay, so if I wanted to use ZipFile to reach inside an egg, what path 
> should I use to open? Is the normalisation code available as a function 
> anywhere?

pkg_resources (part of setuptools, documented on the setuptools 
homepage) abstract the access to data inside packages, no matter whether 
they're in a zipped egg or not.

More information about the Distutils-SIG mailing list