Skip to content

The agent that grows with you

fix(gateway): mark cron interrupt notice as an interim send

kshitijk4poor5f5d0efd03c7
diff --git a/gateway/run_shutdown.py b/gateway/run_shutdown.py
index e8886172505..402f50091d7 100644
--- a/gateway/run_shutdown.py
+++ b/gateway/run_shutdown.py
@@ -944,9 +944,10 @@ class GatewayShutdownMixin:
with _log_suppressed(logging.DEBUG, "Cron interrupt notice to %s:%s raised: %s", platform.value, chat_id):
metadata = self._thread_metadata_for_target(platform, chat_id, thread_id, adapter=adapter)
async def send_notice():
+ from gateway.run import _interim_metadata # races live turns too (#98432)
if await self._send_notice_logged(
adapter, chat_id, msg, platform.value, "Cron interrupt notice to %s:%s failed: %s",
- "Cron interrupt notice to %s:%s raised: %s", metadata=metadata,
+ "Cron interrupt notice to %s:%s raised: %s", metadata=_interim_metadata(metadata),
):
notified.add(dedup_key)
from gateway.warning_notifications import present_notification