In general I think that its ok to have the FindFailed exceptions, because normally a workflow should stop when something is not found. It makes no sense to go on, since something is different from what you expected.
So i use:
import sys
try:
.... click() and all the stuff
.... the workflow
except FindFailed: # possible with 0.9.9
popup(str(sys.exc_info()[1])) # info: line number and picture filename
except Exception:
... all the others
with setThrowException(True/False) you can always switch between the two behaviors.
I think there should be a 3rd parameter for the wait() to tell it, to either throw exception or return None.
well, wait() is a case to think about.
In general I think that its ok to have the FindFailed exceptions, because normally a workflow should stop when something is not found. It makes no sense to go on, since something is different from what you expected.
So i use:
import sys str(sys. exc_info( )[1])) # info: line number and picture filename
try:
.... click() and all the stuff
.... the workflow
except FindFailed: # possible with 0.9.9
popup(
except Exception:
... all the others
with setThrowExcepti on(True/ False) you can always switch between the two behaviors.
I think there should be a 3rd parameter for the wait() to tell it, to either throw exception or return None.