sikuli-driver team mailing list archive
-
sikuli-driver team
-
Mailing list archive
-
Message #50938
Re: [Question #679012]: send email when script stops at error or finishes
Question #679012 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/679012
BOCHENG YIN posted a new comment:
Hi, RailMan,
I try your code as below:
____________________
try:
runScript("./testClick.sikuli")
exit(0) # processed if run ok
except:
print("sikuli crashes")
exit(1)
___________________
testClick.sikuli has code as below:
click(find("1552251843198.png"))
print("find it")
_______________________
when the target image is visible, the result message is
"
find it
sikuli crashes
[info] Exit code: 1
"
When the target images is blocked, the result message is
"
....FindFailed...
sikuli crashes"
[info] Exit code: 1
".
Why it always run the except clause no matter that the script in "try" section can finish or not.
Thanks a lot!
-Bocheng
--
You received this question notification because your team Sikuli Drivers
is an answer contact for Sikuli.