"java.lang.ExceptionInInitializerError" thrown when I run Selenium+sikuli script in Linux

Asked by Srividhya on 2017-03-17

Problem Description
I run my Selenium script from Linux environment. Using Selenium Grid concept, the browser is launched in a Remote desktop(Windows/MAC)
I am using Sikuli for simulating mouse events in my browser.

When I run the script from the linux system, the script fails with the following error,
"<WARNING>Traceback (most recent call last):
  File "/home/aptRoot/tools/python/64/Python-2.7/lib/python2.7/unittest/case.py", line 318, in run
  File "/home/srividra/public_html/testcase/SRIVISIM/Condition_List_edge_Testcase/170317102108/testcase/Condition_List_edge_Testcase.py", line 63, in runTest
    myClass.verifyLog(self.testcase.neip, self.testcase.browser, self.testcase.server_ip, self.testcase.app_name)
java.lang.LinkageErrorPyRaisable: java.lang.ExceptionInInitializerError

This error is thrown when the following line is executed:
"Screen s = new Screen();"

So I am unable to proceed with the execution.
NOTE: The same script is working fine when I run from Eclipse in my local system.
I have set Java path in linux "PATH" variable.

-> echo $PATH

Please guide me on how to proceed here.

Question information

English Edit question
Sikuli Edit question
No assignee Edit question
Last query:
Last reply:
RaiMan (raimund-hocke) said : #1

you have to point to sikulixapi.jar via CLASSPATH environment variable.

Srividhya (sriiviidhyaa) said : #2

Thanks for the reply.. Since I am new to sikuli, can you guide me on how to set this variable

RaiMan (raimund-hocke) said : #3

Sorry, not special for Sikuli, standard Java usage knowledge.

Find out, how in your environment the Java classpath has to be set, so that at runtime Java can find the SikuliX jar.

Can you help with this problem?

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

To post a message you must log in.