This repository has been archived by the owner on Apr 26, 2024. It is now read-only.
Error on shutdown when prescence is enabled #11517
Labels
S-Tolerable
Minor significance, cosmetic issues, low or no impact to users.
T-Defect
Bugs, crashes, hangs, security vulnerabilities, or other reported issues.
Spotted when I was reading through sytest logs.
The problem is that we register a call to
run_as_background_process
before shutdown here. We pass it the callableself._on_shutdown
. The latter is a synchronous function, butrun_as_background_process
expects an async function.synapse/synapse/handlers/presence.py
Lines 416 to 428 in 75ca0a6
The symptom was introduced in #10847 when we removed
maybe_awaitable
. But the underlying cause is that_on_shutdown
didn't return a Deferred back when we expected it to. (PlusaddSystemEventTrigger
obscures the call from mypy. Probably extra confusion when this was rewritten from twisted defers to asyncs.)The text was updated successfully, but these errors were encountered: