[1.1.4]After run [Take screenshot],sikulixIDE window disappear

Asked by Linda on 2019-06-25

1. I click [Take screenshot]
2. Screenshot target region or target picture
3. SikulixIDE disappear
4. I reopen sikulix.jar show
               "Terminating on FatalError:cannot access IDE lock for/nC:\Users\ADMINI~1\AppData\Local\Temp\s_i_k_u_l_i-ide-isrunning"

OS is Windows Server 2019
sikuli version is 1.1.4

Please refer log:

[debug] ButtonCapture: capture!
[debug] ButtonCapture: doPrompt for
[debug] ScreenImage.getFile:
C:\Users\Administrator\AppData\Roaming\Sikulix\SikulixStore\lastScreenShot.png
[debug] CapturePrompt: started at (123,157) as L(123,157) on 0
[debug] CapturePrompt: finished at (218,196) as L(218,196) on 0
[debug] ButtonCapture: update
[debug] RunTimeIDE: addToWindowsSystemPath: added to systempath:
C:\Users\Administrator\AppData\Roaming\Sikulix\SikulixLibs
[debug] RunTimeIDE: checkJavaUsrPath: added to ClassLoader.usrPaths
[debug] RunTimeIDE: libsExport: folder exists: C:\Users\Administrator\AppData\Roaming\Sikulix\SikulixLibs (1.1.4 - 201904201408)
[debug] RunTimeIDE: loadLib: opencv_java342.dll (success)
Exception in thread "AWT-EventQueue-0" java.lang.UnsatisfiedLinkError: The specified module could not be found.

        at com.sun.jna.Native.open(Native Method)
        at com.sun.jna.NativeLibrary.loadLibrary(NativeLibrary.java:288)
        at com.sun.jna.NativeLibrary.getInstance(NativeLibrary.java:427)
        at com.sun.jna.Native.register(Native.java:1647)
        at com.sun.jna.Native.register(Native.java:1360)
        at net.sourceforge.tess4j.TessAPI1.<clinit>(TessAPI1.java:41)
        at org.sikuli.script.TextRecognizer.start(TextRecognizer.java:92)
        at org.sikuli.ide.PatternPaneNaming.getFilenameFromImage(PatternPaneNaming.java:130)
        at org.sikuli.ide.ButtonCapture.update(ButtonCapture.java:144)
        at org.sikuli.util.OverlayCapturePrompt.notifyObserver(OverlayCapturePrompt.java:266)
        at org.sikuli.util.OverlayCapturePrompt$1.mouseReleased(OverlayCapturePrompt.java:138)
        at java.awt.Component.processMouseEvent(Unknown Source)
...

Question information

Language:
English Edit question
Status:
Answered
For:
Sikuli Edit question
Assignee:
No assignee Edit question
Last query:
2019-07-08
Last reply:
2019-07-19
TestMechanic (ndinev) said : #1

Please post video of the problem. Do you have same problems on Windows 10/8

Linda (kkea55534) said : #2

Please refer to the link:
https://inventeccorp-my.sharepoint.com/:u:/g/personal/huang_linda_inventec_com/EcIr0yeb6QhNgPfR4jO373gBxBEgQOgALNCM5-IJo5PM0A?e=3wdIMH

I don't try anothor OS.
But Windows Server 2019 seems Windows 10.

TestMechanic (ndinev) said : #3

Windows 2019 differs a lot from win10

I have ideas for you to try:
-- run sikuli with debug - https://sikulix-2014.readthedocs.io/en/latest/faq/010-command-line.html
-- starting sikuli with "run as" administrator
-- try older versions of sikuli - like 1.1.3

Linda (kkea55534) said : #4

After I reinstall my OS,this problem is solved.
But for a while,this situation is repoduced.
I have no idea what cause this .

I have try:
-- run sikuli with debug - https://sikulix-2014.readthedocs.io/en/latest/faq/010-command-line.html
    I run with commandline: java -jar sikuli.jar -v -c -d
    Log as below:
        [debug] ButtonCapture: capture!
        [debug] ButtonCapture: doPrompt for
        [debug] ScreenImage.getFile:
        C:\Users\Administrator\AppData\Roaming\Sikulix\SikulixStore\lastScreenShot.png
        [debug] CapturePrompt: started at (1,3) as L(1,3) on 0
        [debug] CapturePrompt: finished at (77,75) as L(77,75) on 0
        [debug] ButtonCapture: update
        [debug] RunTimeIDE: libsExport: deleting obsolete libs folders in AppPath
        [debug] RunTimeIDE: addToWindowsSystemPath: added to systempath:
        C:\Users\Administrator\AppData\Roaming\Sikulix\SikulixLibs
        [debug] RunTimeIDE: checkJavaUsrPath: added to ClassLoader.usrPaths
        [debug] RunTimeIDE: libsExport: folder created: C:\Users\Administrator\AppData\Roaming\Sikulix\SikulixLibs (1.1.4 - 201904201408)
        [debug] RunTimeIDE: loadLib: opencv_java342.dll (success)
        Exception in thread "AWT-EventQueue-0" java.lang.UnsatisfiedLinkError: The specified module could not be found.

                at com.sun.jna.Native.open(Native Method)
                at com.sun.jna.NativeLibrary.loadLibrary(NativeLibrary.java:288)
                at com.sun.jna.NativeLibrary.getInstance(NativeLibrary.java:427)
                at com.sun.jna.Native.register(Native.java:1647)
                at com.sun.jna.Native.register(Native.java:1360)
                at net.sourceforge.tess4j.TessAPI1.<clinit>(TessAPI1.java:41)
                at org.sikuli.script.TextRecognizer.start(TextRecognizer.java:92)
                at org.sikuli.ide.PatternPaneNaming.getFilenameFromImage(PatternPaneNaming.java:130)
                at org.sikuli.ide.ButtonCapture.update(ButtonCapture.java:144)
                at org.sikuli.util.OverlayCapturePrompt.notifyObserver(OverlayCapturePrompt.java:266)
                at org.sikuli.util.OverlayCapturePrompt$1.mouseReleased(OverlayCapturePrompt.java:138)
                at java.awt.Component.processMouseEvent(Unknown Source)
                at java.awt.Component.processEvent(Unknown Source)
                at java.awt.Container.processEvent(Unknown Source)
                at java.awt.Window.processEvent(Unknown Source)
                at java.awt.Component.dispatchEventImpl(Unknown Source)
                at java.awt.Container.dispatchEventImpl(Unknown Source)
                at java.awt.Window.dispatchEventImpl(Unknown Source)
                at java.awt.Component.dispatchEvent(Unknown Source)
                at java.awt.EventQueue.dispatchEventImpl(Unknown Source)
                at java.awt.EventQueue.access$500(Unknown Source)
                at java.awt.EventQueue$3.run(Unknown Source)
                at java.awt.EventQueue$3.run(Unknown Source)
                at java.security.AccessController.doPrivileged(Native Method)
                at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
                at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
                at java.awt.EventQueue$4.run(Unknown Source)
                at java.awt.EventQueue$4.run(Unknown Source)
                at java.security.AccessController.doPrivileged(Native Method)
                at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
                at java.awt.EventQueue.dispatchEvent(Unknown Source)
                at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
                at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
                at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
                at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
                at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
                at java.awt.EventDispatchThread.run(Unknown Source)
-- starting sikuli with "run as" administrator
    I run sikuli as administrator
-- try older versions of sikuli - like 1.1.3
   There is no this problem with v1.1.3

RaiMan (raimund-hocke) said : #6

I checked with the latest build of IDE 1.1.4 from today on Windows 10-64 latest on Java 8 and with Java 12.

Linda has in her IDE preferences, that the screenshot's image filename should be generated by trying to read some text from the captured image. This triggers the startup of the Tesseract stuff, which in turn leads to an exception with the Java JNA stuff.

from the log:
....
                at com.sun.jna.Native.register(Native.java:1360)
                at net.sourceforge.tess4j.TessAPI1.<clinit>(TessAPI1.java:41)
                at org.sikuli.script.TextRecognizer.start(TextRecognizer.java:92)
                at org.sikuli.ide.PatternPaneNaming.getFilenameFromImage(PatternPaneNaming.java:130)
                at org.sikuli.ide.ButtonCapture.update(ButtonCapture.java:144)
                at org.sikuli.util.OverlayCapturePrompt.notifyObserver(OverlayCapturePrompt.java:266)
                at org.sikuli.util.OverlayCapturePrompt$1.mouseReleased(OverlayCapturePrompt.java:138)
...

This usually happens if there is a Java classpath in the system environment, that has a JNA version specified, that does not work with SikuliX (it has the version 5.3.1 bundled).

My tests with a clean environment (no Java classpath) did not show up with any problems and named the image files with text, that could be read from the image.

Can you help with this problem?

Provide an answer of your own, or ask Linda for more information if necessary.

To post a message you must log in.