You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I originally came up with the listen helper for my personal code and I am very happy to see it implemented directly in triopg.
Now in asyncpg v0.24 add_listener now allows the callback to a coroutine. This allows the posibility of another message passing strategy where backpressure is allowed.
The callback function could concievably be as simple as:
I originally came up with the listen helper for my personal code and I am very happy to see it implemented directly in triopg.
Now in asyncpg v0.24 add_listener now allows the callback to a coroutine. This allows the posibility of another message passing strategy where backpressure is allowed.
The callback function could concievably be as simple as:
The wrapper is necessary, since the callback is running in asyncio, and MemorySendChannel.send does stuff with trio.lowlevel.current_task().
What do you think?
The text was updated successfully, but these errors were encountered: