Skip to content

Subagent announce delivery broken across multiple surfaces on 2026.2.23 #26867

@Lukavyi

Description

@Lukavyi

Summary

Multiple independent reports confirm that subagent completion announcements fail to deliver on 2026.2.23 across Telegram DMs, bot DM topics, and cron isolated sessions. The common thread: sessions_spawn subagents complete successfully but their results never reach the requester.

Related Issues

Issue Surface Symptom
#25069 Cron + sessions_spawn Cron agent gets "do not poll/sleep" note, ends turn immediately. Subagent completes later but cron session is already dead.
#25961 Telegram DM Gateway logs send ✓ but message never appears in chat. delivery-mirror entry written, no retries triggered.
#26803 Telegram bot DM topics Announce retries 3x then gives up silently. message_thread_id not propagated correctly.
#26741 Main session Subagent results not delivered to main session (announce fails).
#22287 General Wrong session, 30min+ delay, duplicate deliveries (pre-2026.2.23, possibly related).

Root Cause Analysis

There appear to be two distinct bugs introduced or exposed in 2026.2.23:

Bug 1: "do not poll/sleep" note breaks cron isolated sessions (#25069)

The SUBAGENT_SPAWN_ACCEPTED_NOTE was added to sessions_spawn tool results:

"auto-announces on completion, do not poll/sleep.
 The response will be sent back as an user message."

In regular sessions this is correct - the agent should not poll because the announce will come back as a user message.

In cron isolated sessions, the agent turn = the entire run. When the model sees "do not poll", it immediately responds with text ("waiting for subagents...") which ends the cron run. The subagent finishes later but the cron session is dead.

Old behavior (v2026.2.6-3): No note in tool result. Agent would poll/wait for subagents, keeping the turn alive long enough for results to come back.

Introduced in: the refactor that moved spawn logic from sessions-spawn-tool.ts to subagent-spawn.ts and added SUBAGENT_SPAWN_ACCEPTED_NOTE.

Bug 2: Announce send succeeds at RPC level but fails to deliver in Telegram (#25961, #26803)

Gateway send RPC returns and delivery-mirror transcript entries are created, but messages never appear in Telegram. This affects both DMs and bot DM topics.

The announce codepath for subagent completions likely differs from the regular message send path in a way that causes Telegram to silently accept but not deliver (e.g. wrong chat_id format, missing message_thread_id, or hitting a send method that does not actually dispatch).

openclaw message send to the same targets works correctly, confirming the channel is healthy.

Suggested Fixes

For Bug 1 (cron + sessions_spawn):

  • Option A: Suppress SUBAGENT_SPAWN_ACCEPTED_NOTE for cron isolated sessions
  • Option B: Cron runner waits for pending subagent runs before finalizing
  • Option C: Block sessions_spawn in cron isolated sessions and return an error suggesting synchronous execution

For Bug 2 (silent Telegram delivery failure):

  • Audit the announce send codepath vs the regular message send codepath
  • Ensure message_thread_id is propagated for forum topic targets
  • Ensure the Telegram API response message_id is validated (not just ok: true)

Environment

  • Version: 2026.2.23
  • Channel: Telegram (DMs + bot DM topics)
  • Previous working version: 2026.2.6-3 (cron subagents worked, announce delivered)

Impact

High - blocks all subagent-based automation (cron jobs, interactive spawns) from delivering results on Telegram. Affects multiple users independently (#25069 reporter, #25961 reporter, #26803 reporter).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions