Skip to content

bpo-34970: Protect tasks weak set manipulation in asyncio.all_tasks() #9837

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Oct 13, 2018

Conversation

asvetlov
Copy link
Contributor

@asvetlov asvetlov commented Oct 13, 2018

return {t for t in _all_tasks
# NB: set(_all_tasks) is required to protect
# from https://bugs.python.org/issue34970 bug
return {t for t in set(_all_tasks)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you make it a list() call instead of set()?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

@miss-islington
Copy link
Contributor

@asvetlov: Status check is done, and it's a success ✅ .

@miss-islington miss-islington merged commit 97cf082 into python:master Oct 13, 2018
@miss-islington
Copy link
Contributor

Thanks @asvetlov for the PR 🌮🎉.. I'm working now to backport this PR to: 3.7.
🐍🍒⛏🤖

miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Oct 13, 2018
…pythonGH-9837)

https://bugs.python.org/issue34970
(cherry picked from commit 97cf082)

Co-authored-by: Andrew Svetlov <andrew.svetlov@gmail.com>
@bedevere-bot
Copy link

GH-9849 is a backport of this pull request to the 3.7 branch.

@asvetlov asvetlov deleted the issue-34970 branch October 13, 2018 18:13
asvetlov added a commit that referenced this pull request Oct 13, 2018
…GH-9837) (GH-9849)

https://bugs.python.org/issue34970
(cherry picked from commit 97cf082)

Co-authored-by: Andrew Svetlov <andrew.svetlov@gmail.com>
ned-deily pushed a commit to ned-deily/cpython that referenced this pull request Oct 20, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
topic-asyncio type-bug An unexpected behavior, bug, or error
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants