On Thu, Oct 4, 2012 at 6:28 PM, Vinay Sajip <vinay_sa...@yahoo.co.uk> wrote: > I've updated distlib as follows: > > 1. I've added support for the equivalent of "pkg_resources.resource_filename" > for returning a true filesystem path for a resource. I've added info about > this in the "Distlib's design" document, though the reference API has not > been fully updated - I thought I'd see if there was any feedback about the > approach I've used. Code and tests have been added, though.
:-) I still like the "mimic os.listdir but with an additional package argument" API because it has fewer parts. Is there a reason why we can't just fix pkgutil? It is probably much easier to do it in distlib. https://bitbucket.org/dholth/distlib2/src/tip/_distlib2/resources.py implements the distlib resources API using pkg_resources as the implementation. Check out how neat apipkg is in https://bitbucket.org/dholth/distlib2/src/tip/distlib/__init__.py. distlib2 does yet not implement any of the other distlib APIs. > 2. I've added the PyPI client code from distutils2 in distlib.pypi. I only > tweaked it a little to run under 2.x and 3.x from a single code base, > ensuring that all the tests passed. I hope to update it with better support > for finding archives not hosted on PyPI, using hints. +0 > I'm also considering the following changes, which I'd like some feedback on: > > * Merging the distlib.depgraph package into the distlib.database package, as > they are fairly interlinked (e.g. adding requires() and required_by() > methods > to Distribution). +1 obviously since I asked > * Removing depgraph.main() and its test, because I don't think it belongs in > the > library layer, but is better implemented as a utility script. +1 an installer probably only needs the toposort of the dependency graph _______________________________________________ Distutils-SIG maillist - Distutils-SIG@python.org http://mail.python.org/mailman/listinfo/distutils-sig