The agent that grows with you
Python aiai-agentai-agentsanthropicchatgptclaudeclaude-codecodexhermeshermes-agentllmnous-researchopenai
fix(cron): mark live deliveries as final notifications
yoma4b69ba22fc47
diff --git a/cron/scheduler.py b/cron/scheduler.pyindex 964cee49164..52ab85f76a8 100644--- a/cron/scheduler.py+++ b/cron/scheduler.py@@ -3519,10 +3519,14 @@ def _deliver_result(job: dict, content: str, adapters=None, loop=None) -> Optionroute_metadata = {"direct_messages_topic_id": str(thread_id),"job_id": job["id"],+ "notify": True,}# Media metadata mirrors the text routing so attachments land in# the same DM topic instead of the General lane (#22773).- media_metadata = {"direct_messages_topic_id": str(thread_id)}+ media_metadata = {+ "direct_messages_topic_id": str(thread_id),+ "notify": True,+ }else:# Forum-style topic (private chat / supergroup) or non-topic# target: route via message_thread_id (#52060). Put thread_id in@@ -3533,10 +3537,12 @@ def _deliver_result(job: dict, content: str, adapters=None, loop=None) -> Option# anchor, so the metadata key bypasses that check and lets the# adapter route via a plain message_thread_id.route_thread_id = str(thread_id) if thread_id is not None else None- route_metadata = {"job_id": job["id"]}+ route_metadata = {"job_id": job["id"], "notify": True}if route_thread_id:route_metadata["thread_id"] = route_thread_id- media_metadata = {"thread_id": thread_id} if thread_id else None+ media_metadata = {"notify": True}+ if thread_id:+ media_metadata["thread_id"] = thread_id# Relay egress needs a tenant discriminator on the frame: the# connector's fail-closed guard resolves the workspace/guild from