[1.1.0-Beta1] Python errors are not properly reported

Bug #1319399 reported by Sébastien Sablé
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
SikuliX
In Progress
High
RaiMan

Bug Description

Hi,

I have a sikuli Python script (+ full framework) that is working fine with 1.0.1 on Windows 7 - Java 1.7.0_51 64 bits. Running from the command line,
Today I wanted to test with the beta of 1.1.0 2014-05-09-18.

I quickly get a crash but the Java exception is obscure enough that I have no idea where it comes from in my script:

----------- OUTPUT -----------

+++ running this Java

+++ trying to run SikuliX

+++ using: -Xms64M -Xmx512M -Dfile.encoding=UTF-8 -Dsikuli.FromCommandLine -jar C:\SikuliX\sikulix.jar -r C:\Users\sikuli\Desktop\techlog\tests\sikuli\ocean\charts.sikuli

[user (5/14/14 3:17:34 PM)] importing techlog_sikuli

[user (5/14/14 3:17:37 PM)] C:\Users\sikuli\Desktop\techlog\tests\sikuli\techlog_sikuli\images\button\checkbox.png

[user (5/14/14 3:17:37 PM)] C:\Users\sikuli\Desktop\techlog\tests\sikuli\techlog_sikuli\images\button\checkbox_checked.png

[user (5/14/14 3:17:38 PM)] C:\Users\sikuli\Desktop\techlog\tests\sikuli\techlog_sikuli\images\button\choice.png

[user (5/14/14 3:17:38 PM)] C:\Users\sikuli\Desktop\techlog\tests\sikuli\techlog_sikuli\images\button\3button_dockwindow_None.png

[user (5/14/14 3:17:38 PM)] C:\Users\sikuli\Desktop\techlog\tests\sikuli\techlog_sikuli\images\button\choice.png

[user (5/14/14 3:17:38 PM)] finished importing techlog_sikuli

----------- STDERR -----------

java version "1.7.0_51"

Java(TM) SE Runtime Environment (build 1.7.0_51-b13)

Java HotSpot(TM) 64-Bit Server VM (build 24.51-b03, mixed mode)

Exception in thread "MainThread" java.lang.ArrayIndexOutOfBoundsException: 1

 at org.sikuli.scriptrunner.JythonScriptRunner.findErrorSource(JythonScriptRunner.java:279)

 at org.sikuli.scriptrunner.JythonScriptRunner.runPython(JythonScriptRunner.java:206)

 at org.sikuli.scriptrunner.JythonScriptRunner.runScript(JythonScriptRunner.java:148)

 at org.sikuli.basics.SikuliScript.main(SikuliScript.java:199)

 at org.sikuli.ide.SikuliIDE.main(SikuliIDE.java:262)

Thanks in advance

description: updated
description: updated
Revision history for this message
RaiMan (raimund-hocke) wrote : Re: [1.1.0-Beta1] Java exception while running script

There are currently issues with Win XP/7.
So it does not really make sense for you to proceed now.

Nevertheless I would be interested in a debug log.
So if you would do me the favor:

runsikulix.cmd -d 3 -r yourscript >log.txt

and send the log file silently to my mail at https://launchpad.net/~raimund-hocke

Thank you

summary: - [1.1.0 beta1] Java exception while running script
+ [1.1.0-Beta1] Java exception while running script
Revision history for this message
Sébastien Sablé (sable-gmx) wrote :

Thanks. It turns out I had modified the script between 1.0.1 and 1.1.0, so there was actually a Python error in my script (ImportError because of a missing module).

With sikuli 1.0.1, I get a clear Python error message:

[error] script stopped with error in line 7
[error] ImportError ( No module named techlog )

With Sikuli 1.1.0 beta I get the provided Java exception which is much less readable.

So you can change the title of this ticket: Python error are not properly reported

summary: - [1.1.0-Beta1] Java exception while running script
+ [1.1.0-Beta1] Python error are not properly reported
summary: - [1.1.0-Beta1] Python error are not properly reported
+ [1.1.0-Beta1] Python errors are not properly reported
RaiMan (raimund-hocke)
Changed in sikuli:
status: New → In Progress
importance: Undecided → High
assignee: nobody → RaiMan (raimund-hocke)
milestone: none → 1.1.0
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.