I have a program that hangs at some point. Is there a way to interrupt the evaluation and go into debugging mode to see where it got stuck?
Randomly setting breakpoints (or debug messages) to slowly narrow down this point seems like a very uneccessarily inconvenience.
You can do it if you start in debug mode and later press the pause button (at the debug view, select the thread you want to pause).
I'm afraid this does not seem to work for me. Pressing the pause button (you mean the button labelled 'suspend' between 'resume' and 'terminate', right?) does not seem to have any effect at all. Could you try it with the following testcase?
lock = threading.RLock()
print 'Thread 1 acquiring lock...'
print 'Thread 1 holding lock'
print 'Thread 1 released lock'
print 'Thread 2 acquiring lock'
print 'Thread 2 got lock'
print 'Thread 2 released lock'
t1 = threading.Thread(target=run1)
t2 = threading.Thread(target=run2)
Seems that sf has eaten the indentation in the run1 and run2 functions... JFTR record, I tested it with correct indentation.
Sign up for the SourceForge newsletter:
You seem to have CSS turned off.
Please don't fill out this field.