sikuli-driver team mailing list archive
-
sikuli-driver team
-
Mailing list archive
-
Message #34253
Re: [Question #270553]: How to capture errors when starting Sikuli from C# (Selenium)?
Question #270553 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/270553
Status: Open => Answered
RaiMan proposed the following answer:
in the called script you can use
exit(someValue)
where someValue will be, what is reported back as returncode.
In your script you can either use
if not exists(someImage):
exit(1)
or wrap the critical section into a
try:
# the code that might fail with an exception
except:
exit(1)
If you need more detailed reporting back to the caller, the next easiest
solution is a file, that is written in the script and read on return
from the script in your main process.
--
You received this question notification because you are a member of
Sikuli Drivers, which is an answer contact for Sikuli.