0 votes
85 views

Dear all,

Unfortunately I have a problem when I try to run a python script. Everytime, independent of olca version and linux/windows, the modules can not be imported:

from org.openlca.core.database.derby import DerbyDatabase

returns

00:05:07 ERROR org.openlca.app.util.ErrorReporter - failed execute script

org.python.core.PyException: ImportError: No module named derby

at org.python.core.Py.ImportError(Py.java:327)

at org.python.core.imp.import_logic(imp.java:1292)

at org.python.core.imp.import_module_level(imp.java:1371)

at org.python.core.imp.importName(imp.java:1544)

at org.python.core.ImportFunction.__call__(__builtin__.java:1285)

at org.python.core.PyObject.__call__(PyObject.java:433)

at org.python.core.__builtin__.__import__(__builtin__.java:1232)

at org.python.core.imp.importFromAs(imp.java:1636)

at org.python.core.imp.importFrom(imp.java:1611)

at org.python.pycode._pyx11.f$0(<string>:1)

at org.python.pycode._pyx11.call_function(<string>)

at org.python.core.PyTableCode.call(PyTableCode.java:173)

at org.python.core.PyCode.call(PyCode.java:18)

at org.python.core.Py.runCode(Py.java:1703)

at org.python.core.Py.exec(Py.java:1747)

at org.python.util.PythonInterpreter.exec(PythonInterpreter.java:268)

at org.openlca.app.devtools.python.Jython.exec(Jython.java:49)

at org.openlca.app.devtools.python.PythonEditor.lambda$0(PythonEditor.java:47)

at org.openlca.app.WrappedJob.run(WrappedJob.java:30)

at org.eclipse.core.internal.jobs.Worker.run(Worker.java:63)

or

import pandas

00:07:06 ERROR org.openlca.app.util.ErrorReporter - failed execute script

org.python.core.PyException: ImportError: No module named pandas

at org.python.core.Py.ImportError(Py.java:327)

at org.python.core.imp.import_first(imp.java:1232)

at org.python.core.imp.import_module_level(imp.java:1363)

at org.python.core.imp.importName(imp.java:1544)

at org.python.core.ImportFunction.__call__(__builtin__.java:1285)

at org.python.core.PyObject.__call__(PyObject.java:433)

at org.python.core.__builtin__.__import__(__builtin__.java:1232)

at org.python.core.imp.importOne(imp.java:1563)

at org.python.pycode._pyx14.f$0(<string>:1)

at org.python.pycode._pyx14.call_function(<string>)

at org.python.core.PyTableCode.call(PyTableCode.java:173)

at org.python.core.PyCode.call(PyCode.java:18)

at org.python.core.Py.runCode(Py.java:1703)

at org.python.core.Py.exec(Py.java:1747)

at org.python.util.PythonInterpreter.exec(PythonInterpreter.java:268)

at org.openlca.app.devtools.python.Jython.exec(Jython.java:49)

at org.openlca.app.devtools.python.PythonEditor.lambda$0(PythonEditor.java:47)

at org.openlca.app.WrappedJob.run(WrappedJob.java:30)

at org.eclipse.core.internal.jobs.Worker.run(Worker.java:63)

Can anyone help or has an idea?

Thanks a million

Walther

in openLCA by (750 points)
by (3.9k points)
Hi WaltherZeug,
Are you trying to run the script from Tools → Developer tools → Python?
If yes, you won't be able to import panda. Also, I am wondering why you would need DerbyDatabase. Maybe you can explain what you are trying to do?
Regards,
François

Please log in or register to answer this question.

...