At 06:48 PM 1/10/2009 +0100, Tarek Ziadé wrote:
Hello,
I am going to work on a change in Distutils to include a get_metadata API, http://bugs.python.org/issue4908
I don't see yet if this can be hard to do, and I will probably discover it while doing it,
Since this is basically what has been done in setuptools, I thaught that you might wanted to help around for this change ?
I'd suggest looking at the pkg_resources code, particularly find_distributions and its related functions. Note, for example, that egg layouts can be nested (even when zipped!), and that the metadata can have different filenames, depending on the installation format. Version parsing also has certain peculiarities, which also means that people doing simple string comparisons on the version field is probably not going to suffice.