[Async-sig] question re: loop.shutdown_asyncgens()

Chris Jerdonek chris.jerdonek at gmail.com
Fri Jul 28 16:57:11 EDT 2017


Thanks! I'll try to find time to propose a PR.

Also, for suggestions around the new API, would you prefer that be posted
to PR #465, or can it be done here?

--Chris


On Fri, Jul 28, 2017 at 1:45 PM, Yury Selivanov <yselivanov at gmail.com>
wrote:

>
> Thanks,
> Yury
>
> On Jul 28, 2017, 4:38 PM -0400, Chris Jerdonek <chris.jerdonek at gmail.com>,
> wrote:
>
> Thanks, Yury. Have you also considered including recommended setup /
> cleanup boilerplate in a place where it's easy for asyncio users to find,
> like in the asyncio docs here?
> https://docs.python.org/3/library/asyncio-eventloop.html#run-an-event-loop
>
>
>
> Yes, a PR would be welcome!
>
>
> One example of a Python module using this approach is itertools:
> https://docs.python.org/3/library/itertools.html#itertools-recipes
>
> Currently, even the example snippet provided for loop.shutdown_asyncgens():
> https://docs.python.org/3/library/asyncio-eventloop.html#asyncio.
> AbstractEventLoop.shutdown_asyncgens
> is incomplete because it doesn't execute shutdown_asyncgens() in a
> try-finally like you do in your latest patch posted on PR #465.
>
> Also, even if run() is added to Python 3.7, Python 3.6 users would still
> need / benefit from being able to find blessed boilerplate in a central
> place.
>
>
> I was going to release a new module on PyPI called "asyncio_next" or
> something with backports (and to experiment with the proposed APIs before
> 3.7 is out).
>
> Yury
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/async-sig/attachments/20170728/0b2e81b3/attachment-0001.html>


More information about the Async-sig mailing list