CGI Scripts
Will Ware
wware at world.std.com
Fri Feb 18 15:39:17 EST 2000
Thomas A. Bryan (tbryan at python.net) wrote:
> modules_of_interest = ['string', 'cgi', 'math', 'foo']
> for module_name in modules_of_interest:
> try: ....
> except ImportError: ....
I am fooling with a CGI script which does what, to me, looks like
a totally legitimate import from the directory where it itself is.
The directory shows up in sys.path and I can do os.listdir() on it
and see the thing I want to import. Yet I continue to get an
ImportError. I tried the code above to see if I could learn more,
and just got the expected error message.
Are there any deeper or more insight-offering ways to debug
problems with importing? Is there any sort of verbose debug option
that spews out messages about exactly how or why the import failed?
--
- - - - - - - - - - - - - - - - - - - - - - - -
Resistance is futile. Capacitance is efficacious.
Will Ware email: wware @ world.std.com
More information about the Python-list
mailing list