NoClassDefFoundError in wait for image

Bug #1889415 reported by luislupe
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
SikuliX
Invalid
Undecided
Unassigned

Bug Description

I'm using:
  sikulixide-2.0.4.jar
  Linux 5.7.10_1 #1 SMP x86_64

At the second line of the script

openApp("firefox https://www.recheio.pt")
wait("1596027541334.png")

There's an error message:
[error] script [ recheio ] stopped with error in line 2
[error] java.lang.NoClassDefFoundError ( java.lang.NoClassDefFoundError: Could not initialize class org.sikuli.script.Finder$FindInput2 )
[error] --- Traceback --- error source first
line: module ( function ) statement
63: Sikuli ( wait ) return SCREEN.wait(target)
2: main ( <module> ) wait("1596027541334.png")
[error] --- Traceback --- end --------------

Revision history for this message
luislupe (luislupe) wrote :
Revision history for this message
RaiMan (raimund-hocke) wrote :
Revision history for this message
luislupe (luislupe) wrote :

I haven't built from sources yet.

The OpenCV packages that are installed are the ones with the '[*]':

[*] libopencv-3.4.10_1 Computer vision and machine learning software library - library files
[-] libopencv-devel-3.4.10_1 Computer vision and machine learning software library - development files
[-] libopencv-python-3.4.10_1 Computer vision and machine learning software library - Python2 bindings
[*] libopencv-python3-3.4.10_1 Computer vision and machine learning software library - Python3 bindings
[*] libopencv4-4.3.0_3 Computer vision and machine learning software library, version 4.x - library files
[-] libopencv4-devel-4.3.0_3 Computer vision and machine learning software library, version 4.x - development files
[-] libopencv4-python-4.3.0_3 Computer vision and machine learning software library, version 4.x - Python2 bindings
[-] libopencv4-python3-4.3.0_3 Computer vision and machine learning software library, version 4.x - Python3 bindings
[*] opencv-3.4.10_1 Computer vision and machine learning software library
[*] opencv4-4.3.0_3 Computer vision and machine learning software library, version 4.x

After installing the opencv and opencv4 packages, there's the error:
[error] RunTime:loadLib: opencv_java (failed) probably dependent libs missing:
no opencv_java in java.library.path
[error] Save your work, correct the problem and restart the IDE!
[error] script [ recheio ] stopped with error in line 2
[error] java.lang.ExceptionInInitializerError ( java.lang.ExceptionInInitializerError )
[error] --- Traceback --- error source first
line: module ( function ) statement
63: Sikuli ( wait ) return SCREEN.wait(target)
2: main ( <module> ) wait("1596027541334.png")
[error] --- Traceback --- end --------------

Tried to find the libopencv_java file with
find /usr/ -name libopencv_java*
but got no result.

Do you think this file can be obtained from any of the OpenCV packages that are not yet installed (lib...) or my best bet is to install from sources?

Revision history for this message
RaiMan (raimund-hocke) wrote :

You should only have the 3.4 version active (sym-linked) on your system.

Make sure you have a libopencv_java34x.so in your library path.
In doubt create a symlink in /usr/local/lib pointing to the real .so

This is the first level lib that is needed by Sikuli 2.0.4

RaiMan (raimund-hocke)
Changed in sikuli:
status: New → Invalid
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.