Fix Queue.shutdown docs for condition to unblock a join#137088
Merged
rhettinger merged 2 commits intopython:mainpython/cpython:mainfrom Jul 25, 2025
Merged
Fix Queue.shutdown docs for condition to unblock a join#137088rhettinger merged 2 commits intopython:mainpython/cpython:mainfrom
rhettinger merged 2 commits intopython:mainpython/cpython:mainfrom
Conversation
Member
serhiy-storchaka
left a comment
There was a problem hiding this comment.
Confirmed.
Maybe update also the documentation for Queue.join()? It says when the count of unfinished tasks goes up or down. Since the claim that shutdown(immediate=True) calls task_done() was removed (as not literally correct), this no longer covers all cases.
|
Thanks @rhettinger for the PR 🌮🎉.. I'm working now to backport this PR to: 3.13, 3.14. |
|
Sorry, @rhettinger, I could not cleanly backport this to |
miss-islington
pushed a commit
to miss-islington/cpython
that referenced
this pull request
Jul 25, 2025
) (cherry picked from commit ea06ae5) Co-authored-by: Raymond Hettinger <rhettinger@users.noreply.github.com>
|
GH-137102 is a backport of this pull request to the 3.13 branch. |
rhettinger
pushed a commit
that referenced
this pull request
Jul 25, 2025
taegyunkim
pushed a commit
to taegyunkim/cpython
that referenced
this pull request
Aug 4, 2025
Member
|
Reminder about backporting. @rhettinger |
Agent-Hellboy
pushed a commit
to Agent-Hellboy/cpython
that referenced
this pull request
Aug 19, 2025
StanFromIreland
pushed a commit
to StanFromIreland/cpython
that referenced
this pull request
Nov 5, 2025
…ngh-137088) (cherry picked from commit ea06ae5) Co-authored-by: Raymond Hettinger <rhettinger@users.noreply.github.com>
|
GH-141073 is a backport of this pull request to the 3.14 branch. |
Member
|
Backports cleanly, created it. |
kumaraditya303
pushed a commit
that referenced
this pull request
Nov 6, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
I missed this before. A hard shutdown only unblocks a join if all previous gets had a corresponding
task_done.Demonstration:
📚 Documentation preview 📚: https://cpython-previews--137088.org.readthedocs.build/