Erratic import behavior

Alex Martelli aleax at
Sat Mar 22 10:15:11 CET 2003

Jon wrote:
> What I would like to know is why is there a difference in behavior
> between running my code in PythonWin and running it from the command
> prompt?

Not sure, offhand, but, try importing sys and printing sys.path --
does it differ in the two cases?  That might easily explain import
differences.  If it's not that, seeing if PythonWin has import
hooks installed, including possibly just an override of __import__
in the builtins, might help.


More information about the Python-list mailing list