sikuli-driver team mailing list archive
-
sikuli-driver team
-
Mailing list archive
-
Message #32252
Re: [Question #266601]: [1.1.+] cannot be run in headless environment
Question #266601 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/266601
RaiMan proposed the following answer:
no idea, what you are doing/using there, (looks like some overkill:
starting a JVM from inside Python, to run some Sikuli statements?) but
as far as I understand, try this:
import sys
from jpype import *
def startJVM1():
JVM = getDefaultJVMPath()
startJVM(JVM, '-ea',"-Djava.class.path=sikulixapi.jar -Djava.sikuli.Debug=3")
#java.lang.System.setProperty("java.awt.headless", "true");
sikuli = JPackage("org.sikuli.script")
login_window=sikuli.Pattern("edf_icon.png")
window = sikuli.Screen()
window.click(login_window)
shutdownJVM()
if __name__ == "__main__":
startJVM1()
... and maybe, the shutdownJVM() comes too fast after the
window.click???
--
You received this question notification because you are a member of
Sikuli Drivers, which is an answer contact for Sikuli.