help about JPython
Joao Neto
vascog at uol.com.br
Thu Sep 2 20:29:20 EDT 1999
Hi!
I download JPython but I'm unable to run the Python
Interpreter even on the simplest examples.
I'm using Win98 and IE4.0, I already insert the JP directory
into the PATH and CLASSPATH sets.
Let me give you and example:
=============== The program (that compiles ok)
import org.python.util.PythonInterpreter;
import org.python.core.*;
import java.applet.*;
class hello extends Applet {
public void init() {
PythonInterpreter interp = new PythonInterpreter();
PyObject x = interp.eval("2+2");
System.out.println("x: "+x);
}
}
================== when I run it, the java Console gives me this
java.lang.NullPointerException
at org/python/core/PySystemState.<init>
at org/python/util/PythonInterpreter.<init>
at org/python/util/PythonInterpreter.<init>
at hello.init
at com/ms/applet/AppletPanel.securedCall0
at com/ms/applet/AppletPanel.securedCall
at com/ms/applet/AppletPanel.processSentEvent
at com/ms/applet/AppletPanel.processSentEvent
at com/ms/applet/AppletPanel.run
at java/lang/Thread.run
Microsoft (R) VM for Java (tm), 4.0 Release 4.79.0.2424
=============================
can anyone help me?
thanks in advance!!!
joao neto
More information about the Python-list
mailing list