sikuli-driver team mailing list archive
-
sikuli-driver team
-
Mailing list archive
-
Message #46197
Re: [Question #665279]: Instantiating SikuliX classes through API with node-java hangs on Mac
Question #665279 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/665279
RaiMan proposed the following answer:
Apparently there is a problem in the approach of node-java on Mac with the Java
GraphicsEnvironment.getLocalGraphicsEnvironment()
which is the base to evaluate the accessible Graphics devices (screens, printers, ...).
The implementation in this area is system dependent:
on Mac we have the implementing class
sun.awt.CGraphicsEnvironment
which in turn internally accesses some native libraries.
The offending code in SikuliX seems to be (not executed, if java.awt.headless=true):
GraphicsEnvironment genv = GraphicsEnvironment.getLocalGraphicsEnvironment();
GraphicsDevice[] gdevs = genv.getScreenDevices();
To verify you should try to execute just these 2 statements against
plain Java.
If this fails, then you have found a problem with node-java, that should
be reported there.
--
You received this question notification because your team Sikuli Drivers
is an answer contact for Sikuli.