]> git.ipfire.org Git - thirdparty/sqlalchemy/sqlalchemy.git/commit
Allow contextvars to be set in events when using asyncio
authorFederico Caselli <cfederico87@gmail.com>
Thu, 14 Apr 2022 22:29:01 +0000 (00:29 +0200)
committerFederico Caselli <cfederico87@gmail.com>
Sun, 17 Apr 2022 18:23:38 +0000 (20:23 +0200)
commitcaea59258a0003f3e1a0c93f21312ba9ff60abc9
tree2270004208857132a232d262e77d0209919982e7
parent549e3a5be6a8c6db7183b1f7d20e8f3f39687ef4
Allow contextvars to be set in events when using asyncio

Allow setting contextvar values inside async adapted event handlers.
Previously the value set to the contextvar would not be properly
propagated.

Fixes: #7937
Change-Id: I787aa869f8d057579e13e32c749f05f184ffd02a
(cherry picked from commit 640d163bd8bf61e87790255558b6f704a0d06174)
doc/build/changelog/unreleased_14/7937.rst [new file with mode: 0644]
lib/sqlalchemy/util/_concurrency_py3k.py
test/base/test_concurrency_py3k.py