logo       

jythonc and PyObject: msg#00022

lang.jython.user

Subject: jythonc and PyObject

Ok, I am getting rather frustrated with this problem. I cannot get PyObject to compile with -d. I even --addpackages="org.python.core" and --addpackages="org.python.code.*" and --addpackages org.python.core.

org.python.core is listed in the required packages that jythonc lists during its work. however, it does not show up in the directory structure under jpywork.

Here is my Pythonpath:
c:\python22\lib;.;c:\jython;c:\jython\Lib

Here is my classPath:
c:\jython;c:\jython\Lib;c:\j2sdk1.4.1_01\bin;
PathToMyProject\jpywork;

Here is the command I use to compile:

jythonc.bat -d fileToCompile.py

After the compile cycle, I cd jpywork.
java MyFile [cmdLineParam]
Exception in thread "main" java.lang.NoClassDefFoundError: org/python/core/PyObject

I am at a loss. I tried to manually extract the file from jython.jar but when I run:
$ jar -x jython.jar
or jar -t jython.jar

I get no response. It simply hangs.

So, any help would REALLY be appreciated.

Thanks,
Jeff

I was getting this (and other) error messages when trying to do
something similar with a minimal, default sax2 parser and then when
trying to incorporate Piccolo (a zoomable UI based on Java 2D). The >only
approach that I could get to work was to drop print statements into
imported modules and spot classes being imported by name, then
explicitly import these. The errors from Java 2D were fixed by
--addpackages="route.to.class.module,other.route.to.class" (I think >that
this syntax is windows specific).

If it's of any use, I can supply the modules needed to get xmlproc sax2
parser to work.

Does anyone know where this kind of stuff is documented??

tim

-----Original Message----- From: jython-users-admin@xxxxxxxxxxxxxxxxxxxxxxxxxxxxx [mailto:jython-users-admin@xxxxxxxxxxxxxxxxxxxxxxxxxxxxx] On Behalf Of Jeff Quandt Sent: 27 January 2003 17:33 To: jython-users@xxxxxxxxxxxxxxxxxxxxxxxxxxxxx Subject: [Jython-users] jythonc and PyObject I am trying to compile a 90% Python project with jythonc. The only total Jython parts are a Swing Gui. The start up time for the Gui in Jython is horrendous, so I wanted to try compiling and running straight .class files. However, after compiling with jythonc, when I try to run with java, I get a NoClassDefFoundError for org.Python.core.PyObject. The only help on Jythonc I could find talks about subclassing a Java class with a Jython class and then compiling. I can't do this as the project is mostly straight Python and needs to run under python as well as Jython/Java. So, how can I get jythonc to create the .class for PyObject or get around needing it? Any help would be appreciated.

_________________________________________________________________
MSN 8 helps eliminate e-mail viruses. Get 2 months FREE*. http://join.msn.com/?page=features/virus



-------------------------------------------------------
This SF.NET email is sponsored by:
SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See!
http://www.vasoftware.com


<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

News | FAQ | advertise