[Python-Dev] Release manager pronouncement needed: PEP 302 Fix

Phillip J. Eby pje at telecommunity.com
Tue Aug 8 18:04:16 CEST 2006


At 11:11 AM 8/8/2006 -0400, Jean-Paul Calderone wrote:
>On Fri, 28 Jul 2006 18:00:36 -0400, "Phillip J. Eby" 
><pje at telecommunity.com> wrote:
>>At 10:55 PM 7/28/2006 +0200, Martin v. Löwis wrote:
>>>Phillip J. Eby wrote:
>>> > The issue is that a proper fix that caches existence requires adding new
>>> > types to import.c and thus might appear to be more of a feature.  I was
>>> > therefore reluctant to embark upon the work without some assurance 
>>> that it
>>> > wouldn't be rejected as adding a last-minute feature.
>>>
>>>So do you have a patch, or are going to write one?
>>
>>Yes, it's checked in as r50916.
>>
>>It ultimately turned out to be simpler than I thought; only one new type
>>(imp.NullImporter) was required.
>
>Is this going to be the final state of PEP 302 support in Python 2.5?  I
>don't particularly care how this ends up, but I'd like to know what has
>been decided on (PEP 302 doesn't seem to have been updated yet) so I can
>fix Twisted's test suite (which cannot even be run with Python 2.5b3
>right now).

PEP 302 doesn't need to be changed, since Python now conforms to it 
again.  That is, every object in sys.path_importer_cache is either an 
importer or None.  It's just that there is an additional type of importer 
there that didn't occur before.  If you have code that expects only certain 
types of importers to be there, that code was already broken.



More information about the Python-Dev mailing list