[Python-Dev] PEP 376

Tarek Ziadé ziade.tarek at gmail.com
Fri Jul 3 16:44:34 CEST 2009


On Fri, Jul 3, 2009 at 4:28 PM, Nick Coghlan<ncoghlan at gmail.com> wrote:
> I will note (and I believe this is also the main point that Lukasz was
> making) that having the distribution metadata outside the distribution
> as currently proposed in PEP 376 is going to make any eventual PEP 302
> integration much harder - 302 importers only provide a mechanism for
> accessing files inside the distribution, not "adjacent" to them, so the
> mechanism in the PEP doesn't generalise properly.
>
> I suspect this limitation of the PEP 302 APIs is the origin of the
> setuptools format that embeds the metadata inside the distribution - it
> lets you get at the metadata without having to assume that it exists
> directly on the filesystem anywhere.

Maybe we could rework the pkgutil classes for PEP 376 so they look
like an implementation
of the PEP 302 protocol for directories and zip files, with an extra
"get_metadata()" API
and state that it could be an extension for PEP 302 later.


More information about the Python-Dev mailing list