[1.0.1] CommandLine: Return Value and stderr are useless

Bug #1311856 reported by Sandair
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
SikuliX
In Progress
High
RaiMan

Bug Description

When running a Sikuli script from the command line, the return value and stderr are useless for any automated system to determine if a problem occurred.
The script itself can easily return any value, and it can output whatever it wants to stderr, but on the Sikuli side there are problems preventing this to be useful:

1. stderr is used to output non-error stuff (Java version etc)
2. stderr is not used to output errors. E.g.: if there is an syntax error in the script, an "[error] ..." is output to stdout, but not to stderr
3. "[error]..." are reported to stdout for what are not an errors. E.g. The App.window() reports an error if the window size is 0. At best it should be a warning/assert but definitely not an error. In my script, it is perfectly acceptable and should not even warrant a warning.
4. The return is not used to indicate an error: e.g. in the event of a syntax error, the return value is 0. In fact, unless the script exits with a special value, the return value is always 0 regardless of errors.

Windows 7
Sikuli 1.0.1
Command line e.g.: runIDE.cmd -r "c:\testscript\Demo" -- "c:\SomeFolder\myApp.exe"

Revision history for this message
Sandair (friggincomputers) wrote :

The specific error that should not be (from App.window) is this:
[error] Region(0,0,0,0) outside any screen - subsequent actions might not work as expected

Revision history for this message
Sandair (friggincomputers) wrote :

I was mistaken, the scripts cannot output return values to the command line, all I get is a "[info] Exit code: 1" to the stdout, but the actual return value is still 0.

RaiMan (raimund-hocke)
Changed in sikuli:
status: New → In Progress
importance: Undecided → High
assignee: nobody → RaiMan (raimund-hocke)
summary: - Return Value and stderr are useless
+ [1.0.1] Return Value and stderr are useless
summary: - [1.0.1] Return Value and stderr are useless
+ [1.0.1] CommandLine: Return Value and stderr are useless
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.