Problems with import

alexLIGO at googlemail.com alexLIGO at googlemail.com
Tue Dec 4 06:42:28 EST 2007


Hi,

I have some problems when importing a library. Suppose I have a
directory /home/user/pythonlib/package in which I have a python-
library called test.py. Now I want to import that, so I put the
following directory into the PYTHONPATH: /home/user/pythonlib and in
my main python script I put:

from package import test.

BUT I get an error:

ImportError: cannot import name test

So how can I test and check what is going on, why python does not find
the library?


Thanks
  Alex



More information about the Python-list mailing list