This week's book giveaway is in the
We're giving away four copies of a choice of
"Take Control of Upgrading to Yosemite" or "Take Control of Automating Your Mac"
and have Joe Kissell on-line!
A friendly place for programming greenhorns!
Big Moose Saloon
Register / Login
Win a copy of
Take Control of Upgrading to Yosemite
Take Control of Automating Your Mac
this week in the
eclipse+jython import error
Joined: Jun 01, 2009
Jul 02, 2012 04:50:24
I am getting this error
Traceback (innermost last): File "<string>", line 1, in ? ImportError: no module named mymodule at org.python.core.Py.ImportError(Unknown Source) at org.python.core.imp.import_first(Unknown Source) at org.python.core.imp.import_name(Unknown Source) at org.python.core.imp.importName(Unknown Source) at org.python.core.ImportFunction.load(Unknown Source) ..................................................................................
i have a plugin project com.myjython where there is JythonFactory.java which has the folloeing code
PythonInterpreter interpreter = new PythonInterpreter(); interpreter.exec("from com.mypackage import myFile");
I have another plugin project com.mypackage which has pysrc folder with mymodule/myFile.py
Please help me find the reason for this issue.
SCJP 6.0 86%
Joined: Sep 18, 2000
Jul 06, 2012 17:35:35
nobody else has replied, so here it goes.....
first post the code....
second, insure that is the full and complete error message... i think it is, and i think i know the issue, but i need to see the code..
third, if you have fixed this, what did you do?
Joined: Jul 02, 2008
Jul 09, 2012 06:30:25
Is com.mypackage project on the build path ?
Also, please ensure your module folder has an empty __init__.py file
subject: eclipse+jython import error
Issue when to trying check code with pmd
Applet in JSP
calling method from another package
How to create web service in RAD7
All times are in JavaRanch time: GMT-6 in summer, GMT-7 in winter
| Powered by
Copyright © 1998-2014