-
-
Notifications
You must be signed in to change notification settings - Fork 80.7k
Gateway restart can leave Codex custom tool call without output #84727
Copy link
Copy link
Open
Labels
P2Normal backlog priority with limited blast radius.Normal backlog priority with limited blast radius.clawsweeper:linked-pr-openClawSweeper found an open linked pull request for this issue.ClawSweeper found an open linked pull request for this issue.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: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.
Description
Metadata
Metadata
Assignees
Labels
P2Normal backlog priority with limited blast radius.Normal backlog priority with limited blast radius.clawsweeper:linked-pr-openClawSweeper found an open linked pull request for this issue.ClawSweeper found an open linked pull request for this issue.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: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.
Type
Fields
Priority
None yet
Summary
A gateway restart can abort an in-flight Codex app-server custom tool call after Codex has persisted the
custom_tool_callitem but before OpenClaw records the matchingcustom_tool_call_output. The next Codex app-server resume keeps loading that invalid native transcript and repeatedly logs:Proof from a live OpenClaw 2026.5.19 update
During the local update/restart, the gateway drain timed out while an embedded run was active:
After restart, the app-server repeatedly reported the missing output. Redacted local log proof:
The persisted Codex native transcript confirmed the orphan:
The gateway itself recovered and stayed healthy, so this is specifically transcript hygiene after restart abort rather than gateway liveness:
Expected behavior
OpenClaw should not leave Codex-owned native transcripts in a state that Codex rejects on every future resume. On restart abort/recovery, it should either:
custom_tool_call_outputfor orphanedcustom_tool_callrecords before resume.Impact
This produces repeated scary ERROR stderr entries in the gateway log even though the gateway is healthy. It also risks making future Codex app-server resume behavior depend on an invalid provider-owned transcript until someone manually edits the rollout JSONL.