jython problem importing a py file

2006-02-06 Thread didier . prophete
Ok, so I know this is probably a common jython error, but somehow I
can't seem to find an answer to this trivial problem.

Ok, I have the following (simple) directory structure:
$TOP/
__init__.py
py_dir/
__init__.py
util.py

I have:
  PYTHONPATH=$TOP
  CLASSPATH=$TOP

I am now trying to execute the simple python/jython statement: "import
py_dir.util"
If I do a 'cd $TOP' first, then this works fine in python and jython.

But if I do a 'cd $TOP/py_dir', then it still works fine in python, but
jython gives me:
Traceback (innermost last):
   File "", line 1, in ?
ImportError: No module named util

I tried everything I could think of (playing with the __init__.py, the
PYTHONCLASS, the CLASSPATH), but nothing seems to work...

I am doing something wrong here ? 

-Didier

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


Re: jython problem importing a py file

2006-02-07 Thread didier . prophete
kz, you are my new hero :-)
thanks a bunch.

-Didier

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