That was a cool trick, Jeff.  So I tried this:

pig -Dpython.verbose=debug xyz.py

and it's printing a huge log, which I will review, but anything in particular I should look at.

PS:  In case it's not obvious yet, I am a fairly newbie to Python/Jython, so appreciate the patience :)


On Fri, Feb 15, 2013 at 9:23 AM, Jeff Emanuel <jemanuel@frii.com> wrote:
Can you set the jython verbose flag from your pig?  Set it to
comment or debug to get import tracing printout.


On 2/15/2013 9:52 AM, Something Something wrote:
Hello,

I am invoking Jython via Apache Pig like this:

pig xyz.py

(Which internally calls Jython)

This is working fine in production for some time.  Now we want to separate all our 'py' files into different subdirectories. e.g.

./lib/Vehicle.py
./lib/cars/Toyota.py

& so on.  You get the idea.

Now when I added the following lines in my Vehicle.py

from Toyota import Toyota

It gives me ImportError:  No module named Toyota


To fix this I tried changing JYTHONPATH in different ways - even hard coding the path - but it's not helping.  e.g.

pig -DJYTHONPATH=/mypath/cars


Please help.  Thanks.


------------------------------------------------------------------------------
Free Next-Gen Firewall Hardware Offer
Buy your Sophos next-gen firewall before the end March 2013 
and get the hardware for free! Learn more.
http://p.sf.net/sfu/sophos-d2d-feb


_______________________________________________
Jython-users mailing list
Jython-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jython-users