An asyncio example

Terry Reedy tjreedy at udel.edu
Fri Jul 3 17:31:33 EDT 2015


On 7/3/2015 4:33 PM, Adam Bartoš wrote:
>
> On Fri, Jul 3, 2015 at 7:38 PM, Adam Bartoš <drekin at gmail.com
> <mailto:drekin at gmail.com>> wrote:
>
>     Ian Kelly:
>
>     >> 2) In the blocked situaction even KeyboardInterrupt doesn't break the loop,
>     >> is that desired behavior? And why?
>     >
>      > I don't think so. When I tried this locally (using Python 3.4.0, so
>      > replacing "async def" with "def" and "await" with "yield from" and
>      > "loop.create_task" with "asyncio.async") pressing Ctrl-C did
>     interrupt
>      > the loop.
>      >
>     Ok, I'll try to get more information and I'll eventually raise an issue.
>
>
>   I tried it on Python 3.4.1 and Ctrl-C doesn't interrupt the loop.
> Maybe it has something to do with the fact I'm on Windows.

Please try with 3.4.3, which has further asyncio changes.

-- 
Terry Jan Reedy





More information about the Python-list mailing list