
Sept. 15, 2009
6:04 a.m.
On Sep 14, 8:13 pm, Greg Ewing <greg.ew...@canterbury.ac.nz> wrote:
Nick Coghlan wrote:
time.sleep() is actually a great example. Firstly, I didn't use it just yesterday precisely because dropping it in in a naive fashion would have broken Ctrl-C handling
What do you mean? Ctrl-C interrupts time.sleep() okay in my Python (on MacOSX).
It's OS-dependent, apparently. Ctrl-C interrupts for me too on Linux or in Cygwin, but it doesn't work on Windows XP. I sometimes replace sleep() with my own implementation that does small time.sleep()'s in a loop so that it can be interrupted.