← Back to team overview

sikuli-driver team mailing list archive

[Question #263436]: Jython Script works in Eclipse, but not in Command Prompt

 

New question #263436 on Sikuli:
https://answers.launchpad.net/sikuli/+question/263436

My Jython script runs properly when run in eclipse, but fails when run via command line.

I have Sikuli 1.1.0 set up in Eclipse per the instructions found here: https://github.com/RaiMan/SikuliX-2014/wiki/Usage-in-Java-programming. My Jython script starts with:

import org.sikuli.basics.SikulixForJython
from sikuli import *

I've also added C:\SikuliX1.1\sikulixapi.jar to the (pydev) PYTHONPATH. And, as expected, my script works when run.

But, if I navigate to my project in command line and run with the command:

jython -Dpython.path=C:\SikuliX1.1\sikulixapi.jar __init__.py

I get the error:

[error] SikuliXforJython: package: sikuli/__init__.py not found: Sikuli might not work
Traceback (most recent call last):
  File "__init__.py", line 4, in <module>
    from sikuli import *
ImportError: No module named sikuli

Any idea what I'm doing wrong?



-- 
You received this question notification because you are a member of
Sikuli Drivers, which is an answer contact for Sikuli.