I found a possible solution here:
It uses a code like this to force a timeout:
But it seems like the signal module is not present in py60.
signal handler for SIGALRM, just raise an exception
# set timeout
#... urllib.urlretrieve pages
# some error handling
I'm trying with e32.Ao_Timer()
The timer calls timeoutHandler, and the exception is raised (I can see it in the python console), but not captured by the try. Seems like it's launched in a different thread.
raise IOError, "Timeout error"
timer = e32.Ao_timer()
# comms. function here...
# capture exception here...
is there a solution to raise the exception to the thread from where the timer was triggered?