sikuli-driver team mailing list archive
-
sikuli-driver team
-
Mailing list archive
-
Message #24286
Re: [Question #244200]: configparser error in Sikuli 1.0.1
Question #244200 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/244200
Status: Open => Answered
RaiMan proposed the following answer:
Generally:
SikuliX scripting depends on the Python language level 2.5 (this year going to level 2.7) and uses the interpreter Jython (a Java implementation of Python).
If you have modules running in Python there are the following restrictions:
- must be for language level 2.5
- cannot contain any native libraries (many Python modules have that and are called C-based). A Python module can be used with Sikuli either when it is ported to the Jython environment or if it is written Python only (good examples are the XLS access module xldd, xlwt, ...)
What you get in turn: you can use any available Java library directly
from the scripting level. Many Python libs are mostly API compatible
available in the Java World (e.g.Jygments for Pygments).
So check the above prereqs and then at the beginning of your stuff say:
for e in sys.path: print e
to find out where to put your module (really only the python module - usually the folder containing the __init__.py)
Another option:
dir = <abs path to folder containing your module>
if not dir in sys.path: sys.path.append(dir)
things like eggs or install do nothing of value for the Jython/Sikuli
environment.
--
You received this question notification because you are a member of
Sikuli Drivers, which is an answer contact for Sikuli.