Re: Bloody signal handling (in embedded Python code)

2008-07-02 Thread Marcin Krol
Right, I didn't realize before that Python interpreter has its own signal handling routines. Now I am able to handle signals in Python code, but it still barfs on exit: import time import signal import sys def userBreak(sigNum, execFrame): print "Interrupted,,," sys.exit(sigN

Bloody signal handling (in embedded Python code)

2008-07-02 Thread Marcin Krol
Hello everyone, And now for something completely different: signal handling sometimes works, sometimes it doesn't. When I embed following code, it works: count = 0 def test(): global count while True: count += 1 if (count % 10 == 0):