SIGN IN SIGN UP

[3.11] gh-110378: Close invalid generators in contextmanager and asynccontextmanager (GH-110499) (#110589)

contextmanager and asynccontextmanager context managers now close an invalid
underlying generator object that yields more then one value.
(cherry picked from commit 96fed66a65097eac2dc528ce29c9ba676bb07689)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
Co-authored-by: Łukasz Langa <lukasz@langa.pl>
M
Miss Islington (bot) committed
2b3a4182798bc95a426e55d1f9f7199e2f2b5662
Parent: d099def
Committed by GitHub <noreply@github.com> on 10/10/2023, 9:12:52 AM