George Slavin added the comment: The docs say the sleep call will end if a signal is caught, so once the main thread wakes, it won't go back to sleep.
On Sep 6, 2016 12:35 AM, "Andre Merzky" <rep...@bugs.python.org> wrote: > > Andre Merzky added the comment: > > Hi George, > > > From these results, it appears there is no guarentee that the signal > handler will run before the main thread continues execution at the > time.sleep(500) line. This would explain why we advance to the else clause > before the exception is raised. > > To me it looks like the problem pops up *way* before the `sleep(100)` (or > whatever) finishes, in fact it looks consistently like the sleep is indeed > interrupted after one second. I would it thus interpret differently, as > the code should not be able to advance to the `else` clause at that time. > > Is that different for you? > > ---------- > > _______________________________________ > Python tracker <rep...@bugs.python.org> > <http://bugs.python.org/issue27889> > _______________________________________ > ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue27889> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com