-
-
Notifications
You must be signed in to change notification settings - Fork 80.7k
Claude signed thinking blocks can still poison session replay #85781
Copy link
Copy link
Closed
Labels
P1High-priority user-facing bug, regression, or broken workflow.High-priority user-facing bug, regression, or broken workflow.bugSomething isn't workingSomething isn't workingclawsweeper: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: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:auth-providerAuth, provider routing, model choice, or SecretRef resolution may break.Auth, provider routing, model choice, or SecretRef resolution may break.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.maintainerMaintainer-authored PRMaintainer-authored PR
Description
Metadata
Metadata
Assignees
Labels
P1High-priority user-facing bug, regression, or broken workflow.High-priority user-facing bug, regression, or broken workflow.bugSomething isn't workingSomething isn't workingclawsweeper: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: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:auth-providerAuth, provider routing, model choice, or SecretRef resolution may break.Auth, provider routing, model choice, or SecretRef resolution may break.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.maintainerMaintainer-authored PRMaintainer-authored PR
Type
Fields
Priority
None yet
Summary
Claude runs can still fail when session history replays a signed
thinkingblock that the provider rejects.Observed with
github-copilot/claude-opus-4.7:This appears to be a Claude signed-thinking replay issue, not a generic GitHub Copilot issue. Copilot is one affected route because it exposes Claude models and rejects the replayed signed thinking block.
Actual behavior
Continuing an existing session can fail before producing a reply. The logs show the provider rejects the outbound request payload because a historical assistant
thinkingblock contains a signature that is invalid for this replay path.This poisons the session for that model/provider path: subsequent turns keep replaying the incompatible block unless history is sanitized.
Expected behavior
OpenClaw should not replay Claude signed thinking blocks to provider paths that cannot safely accept them.
If a provider/model route cannot preserve Claude thinking continuity safely, the outbound replay history should strip those blocks completely before the request is sent.
Notes
The current policy shape also looks suspicious:
extensions/github-copilot/replay-policy.tssetsdropThinkingBlocks: truefor Claude models, but the shared thinking sanitizer preserves the latest assistant thinking block for native Anthropic continuity. That may be correct for direct Anthropic paths, but it is unsafe for provider routes that reject replayed signed thinking.Relevant areas:
extensions/github-copilot/replay-policy.tssrc/agents/pi-embedded-runner/replay-history.tssrc/agents/pi-embedded-runner/thinking.tssrc/agents/pi-embedded-runner/run/attempt.tsAcceptance criteria
thinkingblocks can continue on affected provider/model routes instead of failing withInvalid signature in thinking block.