-
-
Notifications
You must be signed in to change notification settings - Fork 80.7k
Telegram detached subagents can run silently without liveness or terminal notification #101656
Copy link
Copy link
Open
Labels
P1High-priority user-facing bug, regression, or broken workflow.High-priority user-facing bug, regression, or broken workflow.clawsweeper:fix-shape-clearClawSweeper found a clear likely implementation shape for this issue.ClawSweeper found a clear likely implementation shape for this issue.clawsweeper:needs-maintainer-reviewClawSweeper marked this issue as needing maintainer review before automation.ClawSweeper marked this issue as needing maintainer review before automation.clawsweeper:needs-product-decisionClawSweeper marked this issue as needing a product or behavior decision.ClawSweeper marked this issue as needing a product or behavior decision.clawsweeper:no-new-fix-prClawSweeper does not recommend queueing a new automated fix PR for this issue.ClawSweeper does not recommend queueing a new automated fix PR for this issue.clawsweeper:source-reproClawSweeper found a high-confidence source-level issue reproduction.ClawSweeper found a high-confidence source-level issue reproduction.impact:message-lossChannel message delivery can be lost, duplicated, or misrouted.Channel message delivery can be lost, duplicated, or misrouted.impact:session-stateSession, memory, transcript, context, or agent state can drift or corrupt.Session, memory, transcript, context, or agent state can drift or corrupt.issue-rating: 🦞 diamond lobsterVery strong issue quality with high-confidence source-level or clear reproduction.Very strong issue quality with high-confidence source-level or clear reproduction.maturity:stableIssue affects a taxonomy feature currently scored M4/M5.Issue affects a taxonomy feature currently scored M4/M5.
Description
Metadata
Metadata
Assignees
Labels
P1High-priority user-facing bug, regression, or broken workflow.High-priority user-facing bug, regression, or broken workflow.clawsweeper:fix-shape-clearClawSweeper found a clear likely implementation shape for this issue.ClawSweeper found a clear likely implementation shape for this issue.clawsweeper:needs-maintainer-reviewClawSweeper marked this issue as needing maintainer review before automation.ClawSweeper marked this issue as needing maintainer review before automation.clawsweeper:needs-product-decisionClawSweeper marked this issue as needing a product or behavior decision.ClawSweeper marked this issue as needing a product or behavior decision.clawsweeper:no-new-fix-prClawSweeper does not recommend queueing a new automated fix PR for this issue.ClawSweeper does not recommend queueing a new automated fix PR for this issue.clawsweeper:source-reproClawSweeper found a high-confidence source-level issue reproduction.ClawSweeper found a high-confidence source-level issue reproduction.impact:message-lossChannel message delivery can be lost, duplicated, or misrouted.Channel message delivery can be lost, duplicated, or misrouted.impact:session-stateSession, memory, transcript, context, or agent state can drift or corrupt.Session, memory, transcript, context, or agent state can drift or corrupt.issue-rating: 🦞 diamond lobsterVery strong issue quality with high-confidence source-level or clear reproduction.Very strong issue quality with high-confidence source-level or clear reproduction.maturity:stableIssue affects a taxonomy feature currently scored M4/M5.Issue affects a taxonomy feature currently scored M4/M5.
Type
Fields
Priority
None yet
Summary
When a Telegram-originated agent turn delegates work to a detached/native subagent and the parent session yields, the user can lose all visible feedback while the child continues running.
From Telegram, these states can look identical:
This makes detached subagent work appear unreliable even when the runtime still has internal state and the child is not yet terminal.
Environment
Observed on:
openai/gpt-5.5via OpenAI Codex OAuthNo private workspace paths, chat IDs, user IDs, task names, or session IDs are included here.
Observed behavior
A Telegram message triggered a parent agent turn that delegated work to a detached native subagent. The parent yielded while the child continued.
The child later entered a long
openai/gpt-5.5model request. During that period there was no tool/process activity because the run was waiting inside the model request. The request eventually failed after roughly 15 minutes with a socket-level termination:OpenClaw surfaced this as:
The terminal event did eventually propagate internally: the subagent was marked failed, the parent received an internal task-completion event, and the parent continued. However, from Telegram the user had no reliable liveness or terminal signal until they manually sent a follow-up status message.
In the same investigation, one runtime artifact reported the child trajectory as successful while the transcript/session state showed the child failed with
stopReason:"error"/errorMessage:"terminated". That may be a separate observability bug, but it made the liveness problem harder to diagnose.Expected behavior
Detached background work spawned from a Telegram-originated turn should have a visible liveness and terminal-notification path.
Recommended behavior:
While detached work is active, keep Telegram
typing...alive when safe and possible.After a configurable period of silence, send a sparse full-message heartbeat, for example:
On subagent success, failure, timeout, or blocked completion, send a visible terminal message to the originating Telegram chat unless explicitly suppressed.
Status?or/statusshould report active child runs, current phase, last activity time, elapsed time, and known timeout/deadline from deterministic runtime state.Runtime observability should use one consistent terminal source of truth. Trajectory, transcript, session registry, and user-facing status should not disagree about whether a child run succeeded or failed.
Why this matters
Users should not have to manually poke a Telegram session just to learn whether delegated background work is alive. Without a liveness signal, normal long-running work, a hung model request, and a failed child run all look like silence.
This is especially confusing for always-on deployments where Telegram is the primary operator interface.
Non-goals
Possible implementation shape
/statusor natural-language status requests read from deterministic runtime state, not from model guesses.Related work
Related issues/PRs that appear adjacent but not sufficient by themselves:
The missing piece here is Telegram-visible, non-sensitive liveness and terminal delivery for detached subagent work.