← Back to team overview

sikuli-driver team mailing list archive

Re: [Question #272353]: Importing Python library smtplib

 

Question #272353 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/272353

    Status: Open => Answered

RaiMan proposed the following answer:
you say that you are running the script in SikuliX IDE (final version)
... but then the sys.path should look like this:
C:\Users\RaiMan\AppData\Local\Temp\Sikulix_1336490921\tmp-2133697922.sikuli
C:\SikuliX\Lib
C:\SikuliX\sikulix.jar\Lib
__classpath__
__pyclasspath__/

1st entry is the script folder
2nd and 3rd are standard entries created by the interpreter Jython at startup with respect to the containing jar. The 3rd entry points to the container of all the Jython stuff including the Jython standard libraries (inside the jar).
the last two entries are standard place holders for internal use by the interpreter, so __pyclasspath__ is definitely Jython stuff. 

So please make sure, you have the final SikuliX 1.1.0 and no pointers to
anything when running the SikuliX IDE (it is completely self contained).

The picture is a bit different, when you want to run a SikuliX script from commandline using your own installed Jython (e.g. your
C:\jython2.7.0) and even a bit more different, when running scripts in Eclipse/PyDev.
Come back if it is that, what you want.

Just tested on Windows: works.

-- 
You received this question notification because your team Sikuli Drivers
is an answer contact for Sikuli.