[1.1.4] Windows 7: problem with opencv_java342.dll

Asked by zhenya on 2019-07-30

I'm trying to set up sikulix 1.1.4, write and execute basic test within sikulix ide.
So, here are steps which I made:
1. installed JRE 8u221
2. downloaded all needed files (sikulixapi.jar, sikulix.jar, jython-standalone-2.7.1.jar), put them to one folder
3. launched sikulix.jar
4. wrote "click (<here I added image, it's address is, for example C:\image.png>)" and clicked "run"

test didn't executed, but this error message appeared:
[error] RunTime:Problematic lib: C:\Users\Yevgeniy\AppData\Roaming\Sikulix\SikulixLibs\opencv_java342.dll (...TEMP...)
[error] RunTime:opencv_java342.dll loaded, but it might be a problem with needed dependent libraries
ERROR: ...TEMP...: Can't find dependent libraries
[error] script [ test1 ] stopped with error in line 1
[error] java.lang.ExceptionInInitializerError ( java.lang.ExceptionInInitializerError )
[error] --- Traceback --- error source first
line: module ( function ) statement
1: main ( <module> ) click ("image.png")
[error] --- Traceback --- end --------------

after this I've closed sikulix ide and noticed that jython-standalone-2.7.1.jar dissapeared from sikulix folder - and during next launch warning window displayed saying something like sikulix can't find connected scripting language.

why dependent libraries weren't found?
why jython-standalone-2.7.1.jar dissapered?

and what should I do to make it work?

Question information

Language:
English Edit question
Status:
Answered
For:
Sikuli Edit question
Assignee:
No assignee Edit question
Last query:
2019-07-30
Last reply:
2019-08-07
RaiMan (raimund-hocke) said : #1

What system?

The Jython jar is moved to the Sikulix/Extensions folder at first run ( I will add this to the docs).

On some Windows 7 system variants we have this problem.

To get a full log run from command line:
java -jar <path-to>\sikulix.jar -v -c

zhenya (zhenya.kozhevnikov) said : #2

@RaiMan (raimund-hocke)

System - windows 7 professional, service pack 1, 64-bit.

I'm sorry for probably excess log, I'm just not sure if only error part matters or clue could be found earlier.
Here is commandline log:

C:\Users\Yevgeniy>java -jar C:/autotesting/sikulix/sikulix.jar -v -c
[DEBUG]startUp: IDE: Running: C:\autotesting\sikulix\sikulix.jar
[DEBUG]startUp: IDE: AppData: C:\Users\Yevgeniy\AppData\Roaming\Sikulix
[DEBUG]startUp: IDE: starting
[DEBUG]startUp: IDE: no extensions.txt nor valid content
[DEBUG]startUp: IDE: moving to extensions: C:\autotesting\sikulix\jython-standal
one-2.7.1.jar
[DEBUG]startUp: IDE: adding extension: C:\Users\Yevgeniy\AppData\Roaming\Sikulix
\Extensions\jython-standalone-2.7.1.jar
[DEBUG]startUp: IDE: Classpath: C:\autotesting\sikulix\sikulix.jar;C:\Users\Yevg
eniy\AppData\Roaming\Sikulix\Extensions\jython-standalone-2.7.1.jar
[DEBUG]startUp: IDE: *********************** leaving start

C:\Users\Yevgeniy>[DEBUG]startUp: IDE: no extensions.txt nor valid content
[51 debug] RunTime:temp folder ok: C:\Users\Yevgeniy\AppData\Local\Temp\Sikulix_
2052287767
Options: *** options dump
Options: testing =
Options: OptionsFile = C:\Users\Yevgeniy\AppData\Roaming\Sikulix\SikulixStore\Si
kulixOptions.txt
Options: *** options dump end
***** show environment for 1.1.4-SNAPSHOT-#358-2019-07-30_08:57 API
user.home: C:\Users\Yevgeniy
user.dir (work dir): C:\Users\Yevgeniy
user.name: Yevgeniy
java.io.tmpdir: C:\Users\Yevgeniy\AppData\Local\Temp
running 64Bit(amd64) on w (6.1) from a jar
java 8 version 1.8 vm 25.221-b11 class 52.0 arch 64
app data folder: C:\Users\Yevgeniy\AppData\Roaming\Sikulix
executing jar: C:\autotesting\sikulix\sikulix.jar
*** classpath dump sikulix
  0: file:/C:/autotesting/sikulix/sikulix.jar
  1: file:/C:/Users/Yevgeniy/AppData/Roaming/Sikulix/Extensions/jython-standalon
e-2.7.1.jar
*** classpath dump end
***** show environment end
[161 debug] init user preferences
[162 debug] IDE: running with Locale: en_US
[DEBUG]startUp: IDE: --- Sikuli parameters ---
[DEBUG]startUp: IDE: 1: -v
[DEBUG]startUp: IDE: 2: -c
[169 debug] HotkeyManager: add Capture Hotkey: CTRL+SHIFT 2 (50, 3)
[359 debug] HotkeyManager: add Abort Hotkey: ALT+SHIFT C (67, 9)
[360 debug] IDE: Init ScriptingSupport
[368 debug] IDESupport: enter
[1698 debug] Runner: added: PackedSikulix [skl] text/skl
[1699 debug] Runner: added: Sikulix [] directory/sikulix
[1699 debug] Runner: added: PackedSikulix [zip] application/zip
[1701 debug] Runner: init: class org.sikuli.script.runners.AbstractLocalFileScri
ptRunner: warning: not possible
[1703 debug] Runner: added: Robot [robot] text/robot
[1717 debug] Runner: added: Jython [py] text/jython
[2111 debug] Runner: added: JavaScript [js] text/javascript
[2113 debug] Runner: added: NetworkRunner [] NET
[2113 debug] Runner: added: PowerShell [ps1] text/powershell
[2114 debug] Runner: added: SikulixJar [jar] text/jar
[2115 debug] Runner: added: Text [txt] text/text
[2115 debug] IDESupport: added: Jython
[2116 debug] IDESupport: added: JavaScript
[2118 debug] IDESupport: added: Text
[2119 debug] IDESupport: exit: defaultrunner: Jython (py)
[2122 debug] IDE: Reading Preferences
[2129 debug] Screen: initScreens: starting
[2130 debug] Screen: Accessing: GraphicsEnvironment.getLocalGraphicsEnvironment(
)
[2130 debug] Screen: Accessing: GraphicsEnvironment.getLocalGraphicsEnvironment(
).getScreenDevices()
[2132 debug] Screen: ScreenDevice 0 has (0,0) --- will be primary Screen(0)
[2133 debug] Screen: Monitor 0: (0, 0) 1920 x 1080
[2135 debug] Screen: initScreens: ending
[2135 debug] IDE: Adding components to window
[2147 debug] IDE: [I18N] menuRecent
[2170 debug] IDE: [I18N] menuToolAndroid
[2176 debug] IDE: creating tabbed editor
[2260 debug] IDE: creating message area
[2328 debug] IDE: creating combined work window
[2332 debug] IDE: Putting all together
[2333 debug] IDE: Putting all together - after main pane
[2428 debug] IDE: Putting all together - after toolbar
[2431 debug] IDE: Putting all together - before layout
[2539 debug] IDE: Putting all together - after layout
[2541 debug] IDE: Putting all together - Restore last Session
[2541 debug] IDE: Restore scripts from last session
[2542 debug] IDE: Restore Sikuli script: C:\Users\Yevgeniy\Desktop\test\test1.si
kuli
[2555 debug] EditorPane: created 1564519172568
[2564 debug] EditorPane: loadfile: C:\Users\Yevgeniy\Desktop\test\test1.sikuli
[2568 debug] JythonRunner: starting initialization
[2570 debug] RunTime:resourceLocation: (class org.sikuli.script.support.RunTime)
 /Lib/sikuli
[2573 debug] RunTime:resourceList: having jar: jar:file:/C:/autotesting/sikulix/
sikulix.jar!/Lib/sikuli
[2596 debug] EditorPane: InitTab: (text/jython)
[2597 debug] SikuliEditorKit.read
[2604 debug] ImagePath: new BundlePath: C:\Users\Yevgeniy\Desktop\test\test1.sik
uli
[2605 debug] EditorPane: setFiles: for: C:\Users\Yevgeniy\Desktop\test\test1.sik
uli
[2612 debug] Image: loaded: 1.png (file:C:\Users\Yevgeniy\Desktop\test\test1.sik
uli\1.png)
[2612 debug] Image: cached: 1.png (3 KB) (# 1 KB 3 -- 0 % of 64 MB)
[2622 debug] IDE startup: 2.6 seconds
[debug] RunTime:files exported: 7 from: Lib/sikuli to:
 C:\Users\Yevgeniy\AppData\Roaming\Sikulix\Lib\sikuli
[debug] Jython: added as Jython::sys.path[0]:
C:\Users\Yevgeniy\AppData\Roaming\Sikulix\Lib\site-packages
[debug] Jython: ***** sys.path
 0: C:\Users\Yevgeniy\Desktop\test\test1.sikuli
 1: C:\Users\Yevgeniy\AppData\Roaming\Sikulix\Lib\site-packages
 2: C:\Users\Yevgeniy\AppData\Roaming\Sikulix\Lib
 3: C:\Users\Yevgeniy\AppData\Roaming\Sikulix\Extensions\Lib
 4: C:\Users\Yevgeniy\AppData\Roaming\Sikulix\Extensions\jython-standalone-2.7.1
.jar\Lib
[9005 debug] JythonRunner: ready: version 2.7.1
[debug] Jython: SikulixForJython: init: starting
[debug] Jython: added as Jython::sys.path[0]:
C:\Users\Yevgeniy\AppData\Roaming\Sikulix\Lib\site-packages
[debug] Jython: SikulixForJython: init: success
[debug] Jython: sikuli: Sikuli: starting init
[debug] Jython: use as default region: R[0,0 1920x1080]@S(0)
[debug] Jython: sikuli: Sikuli: ending init
[debug] Jython: use as default region: R[0,0 1920x1080]@S(0)
[debug] Image: reused: 1.png (file:C:\Users\Yevgeniy\Desktop\test\test1.sikuli\1
.png)
[debug] Region: wait: waiting 3.0 secs for 1.png to appear in R[0,0 1920x1080]@S
(0)
[debug] RunTime:addToWindowsSystemPath: added to systempath:
C:\Users\Yevgeniy\AppData\Roaming\Sikulix\SikulixLibs
[debug] RunTime:checkJavaUsrPath: added to ClassLoader.usrPaths
[debug] RunTime:libsExport: folder exists: C:\Users\Yevgeniy\AppData\Roaming\Sik
ulix\SikulixLibs (1.1.4 - 201907300857)
[error] RunTime:Problematic lib: C:\Users\Yevgeniy\AppData\Roaming\Sikulix\Sikul
ixLibs\opencv_java342.dll (...TEMP...)
[error] RunTime:opencv_java342.dll loaded, but it might be a problem with needed
 dependent libraries
ERROR: ...TEMP...: Can't find dependent libraries
[error] script [ test1 ] stopped with error in line 1
[error] java.lang.ExceptionInInitializerError ( java.lang.ExceptionInInitializer
Error )
[error] --- Traceback --- error source first
line: module ( function ) statement
1: main ( <module> ) click ("1.png")
[error] --- Traceback --- end --------------
[debug] RunTime:***** running cleanUp *****

RaiMan (raimund-hocke) said : #3

may be you can find a solution here:
https://bugs.launchpad.net/sikuli/+bug/1797505

zhenya (zhenya.kozhevnikov) said : #4

@RaiMan (raimund-hocke)
Unfortunately, solutions from Bug #1797505 thread are not applicable in my case.
So, I had to make more radical solution - I just switched to previous version of sikulix (to 1.1.3) and everything works now!

I can say more - I've written tests in Atom and ran them with two profiles, each used different sikulixapi version, and:
- (sikulixapi of 1.1.3) everything worked
- (sikulixapi of 1.1.4) failed to find any image

Maybe, this info will give more clues to understanding of this issue.

RaiMan (raimund-hocke) said : #5

Sorry for the inconveniences, but I currently do not have a working Windows 7 to test.

I will try to get one working the next days, but it surely takes some time.

RaiMan (raimund-hocke) said : #6

Made a test in the following environment:
- Windows 7 service pack 1 64 Bit
- Java 8 latest version (221)
- SikuliX IDE latest version 1.1.4 (#364)

I had no problems with the OpenCV DLL.

So I cannot help you.
You have to find out on your system what library problem you have.

Can you help with this problem?

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

To post a message you must log in.