<div dir="ltr">My first thought was to use `async with` but I found that just `with` also works.<br><br>Sorry, but I don't follow how async context manager may be better.</div><br><div class="gmail_quote"><div dir="ltr">On Wed, Jun 8, 2016 at 10:49 AM Yury Selivanov <<a href="mailto:yselivanov@gmail.com">yselivanov@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><br>
> On Jun 8, 2016, at 1:15 PM, Andrew Svetlov <<a href="mailto:andrew.svetlov@gmail.com" target="_blank">andrew.svetlov@gmail.com</a>> wrote:<br>
><br>
> asyncio.timeout behaves like asyncio.wait_for BTW.<br>
> It cancels inner tasks and sends asyncio.TimeoutError to outer.<br>
<br>
Right.  And I think it’s a totally normal behaviour for asyncio.<br>
<br>
The only thing I’d fix in asyncio.timeout() (aside from resolving<br>
Ben’s questions) is to make it use ‘async with’ statement.<br>
<br>
Yury<br>
<br>
</blockquote></div><div dir="ltr">-- <br></div><div data-smartmail="gmail_signature"><div dir="ltr"><div>Thanks,</div>Andrew Svetlov</div></div>