On 12/21/2009 08:35 AM, Gabriel Genellina wrote:
En Sat, 19 Dec 2009 00:18:26 -0300, Peter <vm...@mycircuit.org> escribió:

This was somehow unexpected for me, since in a module using logger.py, I could use either import:

from mylogger import logger  # without package name

or

from of.mylogger import logger  # with package name

but this does not seem to work for the class specification in the config file (only the former works).

Then you have a big problem with the Python search path (sys.path): you
should *not* have two different (absolute) ways to refer to the same
module, ever.
If "of" is a package, it should not be listed in sys.path

Thanks a lot for this helpful advice, in fact the package/module system is for me ( coming from compiled languages with libaries ) the most unintuitive thing in python.

Peter
--
http://mail.python.org/mailman/listinfo/python-list

Reply via email to