On 08Aug2015 18:17, Chris Angelico wrote:
On Sat, Aug 8, 2015 at 6:11 PM, Cameron Simpson wrote:
From:
https://docs.python.org/3/library/signal.html#execution-of-python-signal-handlers
we have:
A Python signal handler does not get executed inside the low-level (C)
signal handler. Instead
On Sat, Aug 8, 2015 at 6:11 PM, Cameron Simpson wrote:
> From:
>
>
> https://docs.python.org/3/library/signal.html#execution-of-python-signal-handlers
>
> we have:
>
> A Python signal handler does not get executed inside the low-level (C)
> signal handler. Instead, the low-level signal handler s
On 08Aug2015 17:08, Chris Angelico wrote:
On Sat, Aug 8, 2015 at 4:56 PM, Ian Kelly wrote:
On Fri, Aug 7, 2015 at 8:44 PM, Chris Angelico wrote:
The exception isn't happening inside sock.accept(), as I explained. So
you can't catch it there.
Where does the exception happen then? Your expla
On Sat, Aug 8, 2015 at 4:56 PM, Ian Kelly wrote:
> On Fri, Aug 7, 2015 at 8:44 PM, Chris Angelico wrote:
>> The exception isn't happening inside sock.accept(), as I explained. So
>> you can't catch it there.
>
> Where does the exception happen then? Your explanation only covered
> why the blockin
On Fri, Aug 7, 2015 at 8:44 PM, Chris Angelico wrote:
> The exception isn't happening inside sock.accept(), as I explained. So
> you can't catch it there.
Where does the exception happen then? Your explanation only covered
why the blocking call cannot be interrupted by it, not why the
exception i
On Sat, Aug 8, 2015 at 3:16 AM, wrote:
>
> Though I still doesn't understand why the exception isn't caught when I'm
> explicitly trying to catch it. I even tried changing the try/except block to
> this:
>
> try:
> connection, _ = sock.accept()
> except KeyboardInterrupt:
> print 'Keyb
On Thursday, August 6, 2015 at 5:46:19 PM UTC-7, Chris Angelico wrote:
> On Fri, Aug 7, 2015 at 10:34 AM, wrote:
> > Despite my "except KeyboardInterrupt", the KeyboardInterrupt forced by the
> > thread.interrupt_main() in the worker thread isn't being caught.
> >
> > Other things worth noting i
On Fri, Aug 7, 2015 at 10:34 AM, wrote:
> Despite my "except KeyboardInterrupt", the KeyboardInterrupt forced by the
> thread.interrupt_main() in the worker thread isn't being caught.
>
> Other things worth noting is that the exception takes about 3 seconds after
> the call to thread.interrupt_