Code
Hub
Workspaces
Following
Digest
Agents
Trending
Connect
MCP
copy
Index your code
hub
/
github.com/python/cpython
/ get_ctx
Method
get_ctx
Lib/test/test_asyncio/test_threads.py:56–57 ·
view source on GitHub ↗
()
Source
from the content-addressed store, hash-verified
54
test_ctx = ContextVar(
'test_ctx'
)
55
56
def
get_ctx():
57
return
test_ctx.get()
58
59
test_ctx.set(
'parrot'
)
60
result = await asyncio.to_thread(get_ctx)
Callers
nothing calls this directly
Calls
1
get
Method · 0.45
Tested by
no test coverage detected