diff --git a/tests/gateway/test_async_session_db.py b/tests/gateway/test_async_session_db.py index c09b5485ae7c..8799bb0a8937 100644 --- a/tests/gateway/test_async_session_db.py +++ b/tests/gateway/test_async_session_db.py @@ -125,8 +125,10 @@ _GATEWAY_FILES = ("gateway/run.py", "gateway/slash_commands.py") # - self._session_db._db.: the sync escape, allowed ONLY where the call is # provably off the event loop — construction (__init__, before the loop # serves) and the run_sync closure (executed in a thread-pool executor). -# Three such sites today; a fourth must be justified and this count bumped. -_ALLOWED_SYNC_DB_ESCAPES = 3 +# Four such sites today (maybe_auto_archive joined maybe_auto_prune_and_vacuum +# in the construction-time maintenance block); a fifth must be justified and +# this count bumped. +_ALLOWED_SYNC_DB_ESCAPES = 4 # Sync helpers that touch SessionDB but are NEVER invoked bare on the loop: # every loop-side call wraps them in ``asyncio.to_thread(...)`` and the only