This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author vxgmichel
Recipients vxgmichel
Date 2018-12-04.13:21:20
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1543929680.9.0.788709270274.issue35409@psf.upfronthosting.co.za>
In-reply-to
Content
As far as I can tell, this issue is different than: https://bugs.python.org/issue34730

I noticed `async_gen.aclose()` raises a GeneratorExit exception if the async generator finalization awaits and silence a failing unfinished future (see example.py).

This seems to be related to a bug in `async_gen_athrow_throw`. In fact, `async_gen.aclose().throw(exc)` does not silence GeneratorExit exceptions. This behavior can be reproduced without asyncio (see test.py).

Attached is a possible patch, although I'm not too comfortable messing with the python C internals. I can make a PR if necessary.
History
Date User Action Args
2018-12-04 13:21:20vxgmichelsetrecipients: + vxgmichel
2018-12-04 13:21:20vxgmichelsetmessageid: <1543929680.9.0.788709270274.issue35409@psf.upfronthosting.co.za>
2018-12-04 13:21:20vxgmichellinkissue35409 messages
2018-12-04 13:21:20vxgmichelcreate