]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
GH-94398: TaskGroup: Fail create_task() during shutdown (GH-94400)
authorGuido van Rossum <guido@python.org>
Thu, 30 Jun 2022 17:10:46 +0000 (10:10 -0700)
committerGitHub <noreply@github.com>
Thu, 30 Jun 2022 17:10:46 +0000 (19:10 +0200)
commit594c3699492bfb007650538726d953cbed55de04
tree0c08bef359427752e98c566d436e5d3208b1b490
parent4261b6bffc0b8bb5c6d4d80578a81b7520f4aefc
GH-94398: TaskGroup: Fail create_task() during shutdown (GH-94400)

Once the task group is shutting down, it should not be possible to create a new task.
Here "shutting down" means `self._aborting` is set, indicating that at least one task
has failed and we have cancelled all others.

Co-authored-by: Ɓukasz Langa <lukasz@langa.pl>
Doc/library/asyncio-task.rst
Lib/asyncio/taskgroups.py
Lib/test/test_asyncio/test_taskgroups.py
Misc/NEWS.d/next/Library/2022-06-29-04-42-56.gh-issue-94398.YOq_bJ.rst [new file with mode: 0644]