Is there a command in Python that lets you say If <code> takes more than x seconds, break?
I think the module `signal' does something like this. Look it up in the python help file.
CODE
import time
limit = 10 #Or some other number that you want it to stop.
a = time.time()
while time.time()-a < limit:
#Actions to take
If you need the try and except, then I assume you can just put it in the loop?
No I think he belives it will hang on a certain command (such as raw_input) but he needs to break after a bit.
Yeah, it's an individual command. In this case it's a HTTPSocket GET command, but the essence is it's one command that takes time.
I'll look into the signal module a bit later; I've got to run right now.