fix(codex): keep progress replies from ending active turns#105290
fix(codex): keep progress replies from ending active turns#105290fazakis wants to merge 6 commits into
Conversation
|
Codex review: needs maintainer review before merge. Reviewed July 12, 2026, 1:23 PM ET / 17:23 UTC. Summary PR surface: Source +103, Tests +139, Other 0. Total +242 across 25 files. Reproducibility: yes. Current main directly terminalizes confirmed Review metrics: 3 noteworthy metrics.
Root-cause cluster Members:
Proposal only: this assessment does not dispatch repair, suppress jobs, mutate sibling items, close, or merge anything. Merge readiness Overall follows the weaker of proof and patch quality, so missing proof can cap an otherwise strong patch. Rank-up moves:
Risk before merge
Maintainer options:
Next step before merge
Maintainer decision needed
Security Review detailsBest possible solution: Adopt one Codex-only explicit-final implementation on current main if maintainers accept the omission behavior, with coverage for omitted/false progress, true final delivery, failed delivery, cross-chat sends, and field stripping. Do we have a high-confidence way to reproduce the issue? Yes. Current main directly terminalizes confirmed Is this the best way to solve the issue? Yes, conditionally. Explicit completion intent is the strongest structural fix because it separates delivery from completion, but it is the best path only after maintainers approve the new omission semantics and select one clean canonical branch. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against 6787c2f65359. Label changesLabel justifications:
Evidence reviewedPR surface: Source +103, Tests +139, Other 0. Total +242 across 25 files. View PR surface stats
What I checked:
Likely related people:
What the crustacean ranks mean
Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics. How this review workflow works
Review history (8 earlier review cycles)
|
e26458e to
e6c1f36
Compare
|
A janela de coordenação passou sem resposta prática do autor, então abri #105365 como sucessora limpa da abordagem de final explícito. Ela preserva o comportamento estrutural desta PR, mas corrige exatamente o achado de revisão: Não estou propondo fechar esta PR por conta própria. A decisão continua simples para maintainers: adotar o contrato explícito em #105365 ou preferir a alternativa prompt-only em #100156. |
|
Author status update All contributor-actionable findings are now addressed on head
|
|
Closing as superseded: #105365 landed on |
Related: #100153
Alternative to #100156.
What Problem This Solves
Fixes an issue where users running Codex with
message_tool_onlysource delivery could receive a progress or acknowledgment reply and then see the active turn end before the promised work or final answer was completed.Why This Change Was Made
This adds explicit delivery intent to current-source
message(action=send)calls for Codexmessage_tool_onlyruns. Sends withfinal: falseor an omittedfinalremain visible but non-terminal; only a successfully delivered current-source send withfinal: truereleases the turn.The prompt and delivery hints tell the model to use commentary for ordinary progress and
final: trueonly after requested work and verification are complete. The internalfinalfield is removed before provider delivery. Other runtimes, delivery modes, channels, and explicit cross-chat sends retain their existing behavior.This is a structural alternative to #100156. That PR reduces the failure through prompt steering; this change keeps the runtime safe when a model still sends a progress message through the message tool.
User Impact
Codex-backed users can receive a visible progress message without losing the rest of the active turn. Completed final replies still terminate cleanly, preserving duplicate-reply prevention and normal turn release.
Evidence
Before the change, a real Telegram direct-chat turn on macOS with OpenClaw 2026.7.2, Codex app-server,
message_tool_only, and GPT-5.6 followed this sequence:Live Telegram verification after the change:
message(action=send, final=false)deliveredPROGRESS_SENT.message(action=send, final=true)deliveredFINAL_SENT.turn.dynamic_tool_terminal_releaseoccurred only afterFINAL_SENT.final=true.Validation after rebasing onto current
mainand refreshing canonical generated fixtures:The optional automated Codex reviewer could not authenticate from the shell (
HTTP 401), so no automated review verdict is claimed.AI-assisted: yes. The implementation, tests, and live reproduction were prepared with Codex assistance and reviewed and validated by the contributor.