Event JSON
{
"id": "77af82e8dbbc47c857b6b016dadf54b2797b38f317c24a88abcdfc24d913eb87",
"pubkey": "6c79e5c5386ee1cbe5b80303c40f8d781831ef78b63ce76c726c3c0b47f622de",
"created_at": 1725975749,
"kind": 1,
"tags": [
[
"t",
"contextvars"
],
[
"t",
"svcs"
],
[
"proxy",
"https://mastodon.social/@mistersql/113113546741977446",
"web"
],
[
"t",
"python"
],
[
"proxy",
"https://mastodon.social/users/mistersql/statuses/113113546741977446",
"activitypub"
],
[
"L",
"pink.momostr"
],
[
"l",
"pink.momostr.activitypub:https://mastodon.social/users/mistersql/statuses/113113546741977446",
"pink.momostr"
],
[
"-"
]
],
"content": "Anyone understand #ContextVars in #python ? I'm trying to add support to #svcs so that when there isn't a web framework with a context to glom onto, that you can use the thread/thread.local/ContextVars and an alternative to the Application/Request that a web framework would provide.\n\nSo far, I can only get it to \"work\" if the ContextVars are globals.\n\nhttps://gist.github.com/matthewdeanmartin/4a4aaa799df7a454b7ddb7230a78a64f#file-thread-py-L21",
"sig": "a0946fa54f770a53dccaa41b0b6b128adeba47bc3c8757b844022fc9197b32aeaf979d3d62d1a8620449597424783e75ddf834af6416210010b0ebde0469bb2a"
}