sikuli-driver team mailing list archive
-
sikuli-driver team
-
Mailing list archive
-
Message #31002
Re: [Question #263462]: Redirecting the Sikuli Logger and the "setLogger: Jython init: we have problems" Error
Question #263462 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/263462
RaiMan proposed the following answer:
just tested on Windows 8 with this command:
java -cp %sikuli%;%jython% org.python.util.jython
got interactive python
>>> import org.sikuli.basics.SikulixForJython
>>> from sikuli import *
>>> class myLogger():
... def callback(message):
... print "redir:", message
...
>>> Debug.setLogger(myLogger())
>>> Debug.setLoggerAll("callback")
True
>>> Debug.log(test)
redir: test
so give it a try (mind the indentation with def and print !)
--
You received this question notification because you are a member of
Sikuli Drivers, which is an answer contact for Sikuli.