-
-
Notifications
You must be signed in to change notification settings - Fork 80.7k
[Bug]: image_generate callbacks from failed isolated cron runs are routed to subsequent runs of the same job #86459
Copy link
Copy link
Closed
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-live-reproClawSweeper needs live local, crabbox, or manual validation to confirm this issue.ClawSweeper needs live local, crabbox, or manual validation to confirm this issue.clawsweeper:queueable-fixClawSweeper marked this issue as an existing queue_fix_pr work candidate.ClawSweeper marked this issue as an existing queue_fix_pr work candidate.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: 🐚 platinum hermitGood issue quality with a plausible reproduction path needing some confirmation.Good issue quality with a plausible reproduction path needing some confirmation.
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-live-reproClawSweeper needs live local, crabbox, or manual validation to confirm this issue.ClawSweeper needs live local, crabbox, or manual validation to confirm this issue.clawsweeper:queueable-fixClawSweeper marked this issue as an existing queue_fix_pr work candidate.ClawSweeper marked this issue as an existing queue_fix_pr work candidate.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: 🐚 platinum hermitGood issue quality with a plausible reproduction path needing some confirmation.Good issue quality with a plausible reproduction path needing some confirmation.
Type
Fields
Priority
None yet
Bug type: Regression (worked before, now fails)
Beta release blocker: No
Summary:
After upgrading to 2026.5.22, when an isolated cron session calls image_generate and terminates before receiving the callback, the pending image is delivered as the first message of the next run of the same job, bypassing the cron prompt entirely.
Steps to reproduce:
Expected behavior:
Orphaned image_generate callbacks from a terminated session should be discarded or ignored. The new run should start with the cron's configured prompt as its first message, as it did in 2026.5.18.
Actual behavior:
The new run receives the stale image as its first user message (seq: 1). The cron prompt is not delivered. The agent processes the image without context, sends it to unrelated channels, and fails with stopReason=toolUse. This cascades: each failed run leaves new orphaned callbacks that poison the next run.
OpenClaw version: 2026.5.22
OS: Ubuntu 24.04
Install method: npm global
Model: anthropic/claude-sonnet-4-6
Provider / routing chain: openclaw -> anthropic
Logs:
Impact and severity:
Additional information:
Last known good: 2026.5.18. First known bad: 2026.5.22.
Workaround: run the agent as a subagent with a different sessionKey (not sharing the cron jobId prefix).
The 2026.5.22 changelog mentions image_generate now uses "separate session-backed background tasks with message-tool completion delivery" — this change appears to be the source of the regression.