René's URL Explorer Experiment


Title: bpo-32309: Add support for contextvars in asyncio.to_thread() by aeros · Pull Request #20278 · python/cpython · GitHub

Open Graph Title: bpo-32309: Add support for contextvars in asyncio.to_thread() by aeros · Pull Request #20278 · python/cpython

X Title: bpo-32309: Add support for contextvars in asyncio.to_thread() by aeros · Pull Request #20278 · python/cpython

Description: The Python programming language. Contribute to python/cpython development by creating an account on GitHub.

Open Graph Description: Allows contextvars from the main thread to be accessed in the separate thread used in asyncio.to_thread(). See the discussion in GH-20143 for context. https://bugs.python.org/issue32309 Automerg...

X Description: Allows contextvars from the main thread to be accessed in the separate thread used in asyncio.to_thread(). See the discussion in GH-20143 for context. https://bugs.python.org/issue32309 Automerg...

Opengraph URL: https://github.com/python/cpython/pull/20278

X: @github

direct link

Domain: github.com

route-pattern/_view_fragments/voltron/pull_requests/show/:user_id/:repository/:id/pull_request_layout(.:format)
route-controllervoltron_pull_requests_fragments
route-actionpull_request_layout
fetch-noncev2:29827be2-8377-feb1-e1c9-c0335b7e552a
current-catalog-service-hashae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b
request-id84B8:2F2BB0:7A9162:A6CE4B:6A4D68FB
html-safe-nonced14b9e378f0c7596255c63d88842a1784ab76ed3c667c51fca41048f7a06fede
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI4NEI4OjJGMkJCMDo3QTkxNjI6QTZDRTRCOjZBNEQ2OEZCIiwidmlzaXRvcl9pZCI6Ijc4ODg5OTI1MzM3NTcxMjY5MDciLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ==
visitor-hmac6d249f38bc3f88310e976fd2edc9a88a198379705f8c9b09e243d3f68747a5ed
hovercard-subject-tagpull_request:421133152
github-keyboard-shortcutsrepository,pull-request-list,pull-request-conversation,pull-request-files-changed,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///voltron/pull_requests_fragments/pull_request_layout
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/_view_fragments/voltron/pull_requests/show/python/cpython/20278/pull_request_layout
twitter:imagehttps://opengraph.githubassets.com/01c65253ced1a7c3764d0c53e24f1d90af01fe4d3d30f79c43269ee745245d87/python/cpython/pull/20278
twitter:cardsummary_large_image
og:imagehttps://opengraph.githubassets.com/01c65253ced1a7c3764d0c53e24f1d90af01fe4d3d30f79c43269ee745245d87/python/cpython/pull/20278
og:image:altAllows contextvars from the main thread to be accessed in the separate thread used in asyncio.to_thread(). See the discussion in GH-20143 for context. https://bugs.python.org/issue32309 Automerg...
og:image:width1200
og:image:height600
og:site_nameGitHub
og:typeobject
og:author:usernameaeros
hostnamegithub.com
expected-hostnamegithub.com
None7db3950e3f59095e20a9789440c3dd554efc62d434882ead06ae05b5815605b9
turbo-cache-controlno-cache
go-importgithub.com/python/cpython git https://github.com/python/cpython.git
octolytics-dimension-user_id1525981
octolytics-dimension-user_loginpython
octolytics-dimension-repository_id81598961
octolytics-dimension-repository_nwopython/cpython
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id81598961
octolytics-dimension-repository_network_root_nwopython/cpython
turbo-body-classeslogged-out env-production page-responsive
disable-turbofalse
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
releasecd8f6a71db61d6012a0cbb134be844fdbe9b8a45
ui-targetfull
theme-color#1e2327
color-schemelight dark

Links:

Skip to contenthttps://github.com/python/cpython/pull/20278#start-of-content
https://github.com/
Sign in https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fpython%2Fcpython%2Fpull%2F20278
GitHub CopilotWrite better code with AIhttps://github.com/features/copilot
GitHub Copilot appDirect agents from issue to mergehttps://github.com/features/ai/github-app
MCP RegistryNewIntegrate external toolshttps://github.com/mcp
ActionsAutomate any workflowhttps://github.com/features/actions
CodespacesInstant dev environmentshttps://github.com/features/codespaces
IssuesPlan and track workhttps://github.com/features/issues
Code ReviewManage code changeshttps://github.com/features/code-review
GitHub Advanced SecurityFind and fix vulnerabilitieshttps://github.com/security/advanced-security
Code securitySecure your code as you buildhttps://github.com/security/advanced-security/code-security
Secret protectionStop leaks before they starthttps://github.com/security/advanced-security/secret-protection
Why GitHubhttps://github.com/why-github
Documentationhttps://docs.github.com
Bloghttps://github.blog
Changeloghttps://github.blog/changelog
Marketplacehttps://github.com/marketplace
View all featureshttps://github.com/features
Enterpriseshttps://github.com/enterprise
Small and medium teamshttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
App Modernizationhttps://github.com/solutions/use-case/app-modernization
DevSecOpshttps://github.com/solutions/use-case/devsecops
DevOpshttps://github.com/solutions/use-case/devops
CI/CDhttps://github.com/solutions/use-case/ci-cd
View all use caseshttps://github.com/solutions/use-case
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
View all industrieshttps://github.com/solutions/industry
View all solutionshttps://github.com/solutions
AIhttps://github.com/resources/articles?topic=ai
Software Developmenthttps://github.com/resources/articles?topic=software-development
DevOpshttps://github.com/resources/articles?topic=devops
Securityhttps://github.com/resources/articles?topic=security
View all topicshttps://github.com/resources/articles
Customer storieshttps://github.com/customer-stories
Events & webinarshttps://github.com/resources/events
Ebooks & reportshttps://github.com/resources/whitepapers
Business insightshttps://github.com/solutions/executive-insights
GitHub Skillshttps://skills.github.com
Documentationhttps://docs.github.com
Customer supporthttps://support.github.com
Community forumhttps://github.com/orgs/community/discussions
Trust centerhttps://github.com/trust-center
Partnershttps://github.com/partners
View all resourceshttps://github.com/resources
GitHub SponsorsFund open source developershttps://github.com/sponsors
Security Labhttps://securitylab.github.com
Maintainer Communityhttps://maintainers.github.com
Acceleratorhttps://github.com/accelerator
GitHub Starshttps://stars.github.com
Archive Programhttps://archiveprogram.github.com
Topicshttps://github.com/topics
Trendinghttps://github.com/trending
Collectionshttps://github.com/collections
Enterprise platformAI-powered developer platformhttps://github.com/enterprise
GitHub Advanced SecurityEnterprise-grade security featureshttps://github.com/security/advanced-security
Copilot for BusinessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/premium-support
Pricinghttps://github.com/pricing
Search syntax tipshttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
documentationhttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
Sign in https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fpython%2Fcpython%2Fpull%2F20278
Sign up https://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fvoltron%2Fpull_requests_fragments%2Fpull_request_layout&source=header-repo&source_repo=python%2Fcpython
Reloadhttps://github.com/python/cpython/pull/20278
Reloadhttps://github.com/python/cpython/pull/20278
Reloadhttps://github.com/python/cpython/pull/20278
Please reload this pagehttps://github.com/python/cpython/pull/20278
python https://github.com/python
cpythonhttps://github.com/python/cpython
Please reload this pagehttps://github.com/python/cpython/pull/20278
Notifications https://github.com/login?return_to=%2Fpython%2Fcpython
Fork 34.8k https://github.com/login?return_to=%2Fpython%2Fcpython
Star 73.6k https://github.com/login?return_to=%2Fpython%2Fcpython
Code https://github.com/python/cpython
Issues 5k+ https://github.com/python/cpython/issues
Pull requests 2.3k https://github.com/python/cpython/pulls
Actions https://github.com/python/cpython/actions
Projects https://github.com/python/cpython/projects
Security and quality 0 https://github.com/python/cpython/security
Insights https://github.com/python/cpython/pulse
Code https://github.com/python/cpython
Issues https://github.com/python/cpython/issues
Pull requests https://github.com/python/cpython/pulls
Actions https://github.com/python/cpython/actions
Projects https://github.com/python/cpython/projects
Security and quality https://github.com/python/cpython/security
Insights https://github.com/python/cpython/pulse
miss-islingtonhttps://github.com/miss-islington
python:masterhttps://github.com/python/cpython/tree/master
aeros:bpo32309-to_thread-contextvarshttps://github.com/aeros/cpython/tree/bpo32309-to_thread-contextvars
Conversationhttps://github.com/python/cpython/pull/20278
Commits2 (2)https://github.com/python/cpython/pull/20278/commits
Checkshttps://github.com/python/cpython/pull/20278/checks
Files changedhttps://github.com/python/cpython/pull/20278/files
bpo-32309: Add support for contextvars in asyncio.to_thread()https://github.com/python/cpython/pull/20278#top
miss-islingtonhttps://github.com/miss-islington
python:masterhttps://github.com/python/cpython/tree/master
aeros:bpo32309-to_thread-contextvarshttps://github.com/aeros/cpython/tree/bpo32309-to_thread-contextvars
https://github.com/aeros
aeroshttps://github.com/aeros
May 21, 2020https://github.com/python/cpython/pull/20278#issue-622226503
Please reload this pagehttps://github.com/python/cpython/pull/20278
discussionhttps://github.com/python/cpython/pull/20143#discussion_r427808225
GH-20143https://github.com/python/cpython/pull/20143
https://bugs.python.org/issue32309https://bugs.python.org/issue32309
@aeroshttps://github.com/aeros
Please reload this pagehttps://github.com/python/cpython/pull/20278
https://github.com/aeros
https://github.com/JrooTJunior
Add support for contextvars in asyncio.to_thread()https://github.com/python/cpython/pull/20278/commits/6b322fdd8284b69e7785eccc28ec038f633b75b9
6b322fdhttps://github.com/python/cpython/pull/20278/commits/6b322fdd8284b69e7785eccc28ec038f633b75b9
https://github.com/aeros
aeroshttps://github.com/aeros
1st1https://github.com/1st1
asvetlovhttps://github.com/asvetlov
code ownershttps://github.com/python/cpython/blob/df2e0ff0d63b07a1c8fdfd3674d99bd4f2fb69c5/.github/CODEOWNERS#L8
May 21, 2020 03:48https://github.com/python/cpython/pull/20278#event-3359134310
https://github.com/the-knights-who-say-ni
the-knights-who-say-nihttps://github.com/the-knights-who-say-ni
CLA signed https://github.com/python/cpython/issues?q=state%3Aopen%20label%3A%22CLA%20signed%22
May 21, 2020https://github.com/python/cpython/pull/20278#event-3359134401
https://github.com/bedevere-bot
bedevere-bothttps://github.com/bedevere-bot
awaiting core review https://github.com/python/cpython/issues?q=state%3Aopen%20label%3A%22awaiting%20core%20review%22
May 21, 2020https://github.com/python/cpython/pull/20278#event-3359134459
https://github.com/aeros
aeroshttps://github.com/aeros
topic-asyncio https://github.com/python/cpython/issues?q=state%3Aopen%20label%3Atopic-asyncio
needs backport to 3.9 https://github.com/python/cpython/issues?q=state%3Aopen%20label%3A%22needs%20backport%20to%203.9%22
skip news https://github.com/python/cpython/issues?q=state%3Aopen%20label%3A%22skip%20news%22
May 21, 2020https://github.com/python/cpython/pull/20278#event-3359134850
https://github.com/aeros
aeroshttps://github.com/aeros
May 21, 2020https://github.com/python/cpython/pull/20278#issuecomment-631863136
GH-20143https://github.com/python/cpython/pull/20143
@1st1https://github.com/1st1
Please reload this pagehttps://github.com/python/cpython/pull/20278
https://github.com/1st1
1st1https://github.com/1st1
May 21, 2020 https://github.com/python/cpython/pull/20278#pullrequestreview-415869990
View reviewed changes https://github.com/python/cpython/pull/20278/files/6b322fdd8284b69e7785eccc28ec038f633b75b9
Doc/library/asyncio-task.rsthttps://github.com/python/cpython/pull/20278/files/6b322fdd8284b69e7785eccc28ec038f633b75b9#diff-5e9a5bb933b1bd1d6092f7e5adb5c06da7a6792e0597f55f911245acacfce7a7
Please reload this pagehttps://github.com/python/cpython/pull/20278
https://github.com/1st1
1st1https://github.com/1st1
May 21, 2020 https://github.com/python/cpython/pull/20278#pullrequestreview-415870187
View reviewed changes https://github.com/python/cpython/pull/20278/files/6b322fdd8284b69e7785eccc28ec038f633b75b9
1st1https://github.com/1st1
https://github.com/python/cpython/pull/20278#pullrequestreview-415870187
Learn morehttps://docs.github.com/articles/managing-disruptive-comments/#hiding-a-comment
Please reload this pagehttps://github.com/python/cpython/pull/20278
https://github.com/bedevere-bot
bedevere-bothttps://github.com/bedevere-bot
awaiting merge https://github.com/python/cpython/issues?q=state%3Aopen%20label%3A%22awaiting%20merge%22
awaiting core review https://github.com/python/cpython/issues?q=state%3Aopen%20label%3A%22awaiting%20core%20review%22
May 21, 2020https://github.com/python/cpython/pull/20278#event-3359193328
https://github.com/aeros
Fix asyncio.to_thread() docshttps://github.com/python/cpython/pull/20278/commits/9d3fd5ed283cb6acf551dc4abe53e8fe4c9c7df8
9d3fd5ehttps://github.com/python/cpython/pull/20278/commits/9d3fd5ed283cb6acf551dc4abe53e8fe4c9c7df8
https://github.com/aeros
aeroshttps://github.com/aeros
🤖 automerge https://github.com/python/cpython/issues?q=state%3Aopen%20label%3A%22%3Arobot%3A%20automerge%22
May 21, 2020https://github.com/python/cpython/pull/20278#event-3359249406
https://github.com/miss-islington
miss-islingtonhttps://github.com/miss-islington
May 21, 2020https://github.com/python/cpython/pull/20278#issuecomment-631887264
@aeroshttps://github.com/aeros
Please reload this pagehttps://github.com/python/cpython/pull/20278
https://github.com/miss-islington
miss-islingtonhttps://github.com/miss-islington
0f56263https://github.com/python/cpython/commit/0f56263e62ba91d0baae40fb98947a3a98034a73
May 21, 2020https://github.com/python/cpython/pull/20278#event-3359287674
https://github.com/miss-islington
miss-islingtonhttps://github.com/miss-islington
May 21, 2020https://github.com/python/cpython/pull/20278#issuecomment-631887278
@aeroshttps://github.com/aeros
Please reload this pagehttps://github.com/python/cpython/pull/20278
https://github.com/bedevere-bot
bedevere-bothttps://github.com/bedevere-bot
awaiting merge https://github.com/python/cpython/issues?q=state%3Aopen%20label%3A%22awaiting%20merge%22
May 21, 2020https://github.com/python/cpython/pull/20278#event-3359287741
miss-islingtonhttps://github.com/miss-islington
May 21, 2020 https://github.com/python/cpython/pull/20278#ref-commit-a63abf6
https://github.com/aeros
https://github.com/miss-islington
bpo-32309: Add support for contextvars in asyncio.to_thread() (https://github.com/miss-islington/cpython/commit/a63abf650006adcc70c93347c59ca495f1f5285f
python…https://github.com/python/cpython/pull/20278
a63abf6https://github.com/miss-islington/cpython/commit/a63abf650006adcc70c93347c59ca495f1f5285f
…GH-20278https://github.com/python/cpython/pull/20278
https://github.com/python/cpython/pull/20143GH-discussion_r427808225https://github.com/python/cpython/pull/20143GH-discussion_r427808225
pythonGH-20143https://github.com/python/cpython/pull/20143
@aeroshttps://github.com/aeros
0f56263https://github.com/miss-islington/cpython/commit/0f56263e62ba91d0baae40fb98947a3a98034a73
https://github.com/bedevere-bot
bedevere-bothttps://github.com/bedevere-bot
needs backport to 3.9 https://github.com/python/cpython/issues?q=state%3Aopen%20label%3A%22needs%20backport%20to%203.9%22
May 21, 2020https://github.com/python/cpython/pull/20278#event-3359288166
https://github.com/bedevere-bot
bedevere-bothttps://github.com/bedevere-bot
May 21, 2020https://github.com/python/cpython/pull/20278#issuecomment-631887330
GH-20279https://github.com/python/cpython/pull/20279
3.9 branchhttps://github.com/python/cpython/tree/3.9
Please reload this pagehttps://github.com/python/cpython/pull/20278
miss-islingtonhttps://github.com/miss-islington
May 21, 2020 https://github.com/python/cpython/pull/20278#ref-commit-3e65054
https://github.com/miss-islington
https://github.com/aeros
bpo-32309https://bugs.python.org/issue?@action=redirect&bpo=32309
: Add support for contextvars in asyncio.to_thread() (https://github.com/python/cpython/commit/3e650545bfe949fa435b0d41e54986f615891ec8
GH-20278https://github.com/python/cpython/pull/20278
)https://github.com/python/cpython/commit/3e650545bfe949fa435b0d41e54986f615891ec8
3e65054https://github.com/python/cpython/commit/3e650545bfe949fa435b0d41e54986f615891ec8
https://github.com/python/cpython/pull/20143GH-discussion_r427808225https://github.com/python/cpython/pull/20143GH-discussion_r427808225
GH-20143https://github.com/python/cpython/pull/20143
@aeroshttps://github.com/aeros
0f56263https://github.com/python/cpython/commit/0f56263e62ba91d0baae40fb98947a3a98034a73
https://github.com/aeros
aeroshttps://github.com/aeros
May 21, 2020 https://github.com/python/cpython/pull/20278#ref-pullrequest-619591396
bpo-32309: Implement asyncio.to_thread() #20143 https://github.com/python/cpython/pull/20143
arturoescaiphttps://github.com/arturoescaip
May 24, 2020 https://github.com/python/cpython/pull/20278#ref-commit-fbc22f8
https://github.com/aeros
https://github.com/arturoescaip
bpo-32309: Add support for contextvars in asyncio.to_thread() (https://github.com/arturoescaip/cpython/commit/fbc22f81ce2eb360609f8570eecfa25bf00d9036
python…https://github.com/python/cpython/pull/20278
fbc22f8https://github.com/arturoescaip/cpython/commit/fbc22f81ce2eb360609f8570eecfa25bf00d9036
…GH-20278https://github.com/python/cpython/pull/20278
python#20143 (comment)https://github.com/python/cpython/pull/20143#discussion_r427808225
pythonGH-20143https://github.com/python/cpython/pull/20143
@aeroshttps://github.com/aeros
https://github.com/apps/coderabbitai
coderabbitaihttps://github.com/apps/coderabbitai
May 16, 2026 https://github.com/python/cpython/pull/20278#ref-pullrequest-4458215994
tryon: bound Vertex predict on a shared BoundedThreadRunner William-Hill/ptso_agent#248 https://github.com/William-Hill/ptso_agent/pull/248
https://github.co/hiddenchars
https://github.com/python/cpython/pull/{{ revealButtonHref }}
Sign up for freehttps://github.com/join?source=comment-repo
Sign in to commenthttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fpython%2Fcpython%2Fpull%2F20278
https://github.com/1st1
1st1 https://github.com/1st1
https://github.com/python/cpython/pull/20278/files/6b322fdd8284b69e7785eccc28ec038f633b75b9
https://github.com/asvetlov
asvetlov https://github.com/asvetlov
skip news https://github.com/python/cpython/issues?q=state%3Aopen%20label%3A%22skip%20news%22
topic-asyncio https://github.com/python/cpython/issues?q=state%3Aopen%20label%3Atopic-asyncio
Please reload this pagehttps://github.com/python/cpython/pull/20278
https://github.com/aeros
https://github.com/miss-islington
https://github.com/bedevere-bot
https://github.com/1st1
https://github.com/the-knights-who-say-ni
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Viewport: width=device-width


URLs of crawlers that visited me.