[Python-Dev] Re: Proposed Python api for testing whether a module exists

Paul Moore pf_moore at yahoo.co.uk
Mon Aug 2 19:09:57 CEST 2004


Jim Fulton <jim at zope.com> writes:

> I propose to add the following function to the imp module:
>
>    exists(module_name)
[...]
> If there are no objections, I'll try to get this in before Wednesday night.

Does this work in the presence of PEP 302 style import hooks?
Specifically, the case where there's a zipfile on sys.path.

Paul.
-- 
A little inaccuracy sometimes saves tons of explanation -- Saki



More information about the Python-Dev mailing list