Repository navigation
fix: show authoritative tool outcomes - #163545
Conversation
|
🦞👀 Pull request received. I will update this pull request when review starts. ClawSweeper review completeClawSweeper finished reviewing this revision. The review result is being finalized. |
|
Codex review: needs maintainer review before merge. Reviewed October 3, 2026, 4:46 PM ET / 20:46 UTC (Revision 8). ClawSweeper reviewWhat this changesThe PR makes Control UI show active tools as Running and preserves Codex’s reported outcomes for Wait and same-ID collaboration calls. Merge readiness✅ Ready for maintainer review The fix remains necessary on current main, and both previous findings are resolved. No blocking correctness or security finding remains; this member-authored PR should remain open for normal landing. Priority: P2 Review scores
Verification
How this fits togetherThe Codex plugin translates app-server tool events into OpenClaw’s transcript. Control UI combines that history with live run facts to display tool progress and outcomes. flowchart LR
A[Codex tool events] --> B[Transcript projection]
B --> C[Tool history]
C --> E[Outcome resolver]
D[Live run facts] --> E
E --> F[Visible tool status]
Before mergeNone. Agent review detailsSecurityNone. PR surfaceSource +18, Tests +210. Total +228 across 6 files. View PR surface stats
Review metrics
Root-cause clusterRelationship: Members:
Proposal only: this assessment does not dispatch repair, suppress jobs, mutate sibling items, close, or merge anything. Technical reviewBest possible solution: Keep outcome decisions in the existing transcript projector and UI resolver, preserving exact response content and uncertainty when no trustworthy terminal fact exists. Do we have a high-confidence way to reproduce the issue? Yes, from source: active status-less history masks live-running facts, and current main excludes same-ID collaboration terminal results. This review inspected regressions and screenshots without executing a reproduction. Is this the best way to solve the issue? Yes. The patch repairs the existing outcome owners, uses exact identities and result envelopes, and preserves unknown terminal outcomes rather than inventing success. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against 930bd387bbaa. LabelsLabel changes: No label changes. Label justifications:
EvidenceWhat I checked:
Likely related people:
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
HistoryReview history (7 earlier review cycles)
|
98b0930 to
aab5fcc
Compare
|
@clawsweeper re-review The interrupted collaboration finding is fixed at the shared Codex item-status owner, with before/after completion notification-boundary regressions. Exact pinned Codex 0.150.1 contract inspected; focused tests, changed gates, and fresh P2 autoreview are clean on |
|
🦞👀 Re-review progress:
|
|
@clawsweeper re-review The late status-less terminal-row finding is fixed at the outcome resolver. Status-less activity now means Running only for an active unfinished live row; terminal rows remain Outcome unknown. The extended boundary regression failed on the prior head as |
|
🦞👀 Re-review progress:
|
7601fa9 to
feda071
Compare
|
@clawsweeper re-review Rebased onto current main after #164116 changed the same Codex transcript owner. The conflict resolution preserves main's newer code-mode native-call projection and reapplies only this PR's same-ID collaboration/Wait correlation plus active-vs-terminal UI outcome logic. Exact Codex 0.160.0 tag inspected ( |
|
🦞👀 Re-review progress:
|
* fix: show authoritative tool outcomes * test(ui): align active tool outcome expectation * fix(codex): preserve interrupted collaboration outcomes * fix(ui): preserve unknown terminal tool outcomes
Closes #163543
Supersedes the narrower Wait-only fix in #160450.
What Problem This Solves
Fixes: Control UI labels active and authoritatively completed Codex tool calls as Outcome unknown when a status-less history placeholder or discarded native terminal item wins projection.
User Impact
User impact: active tool rows now show Running, and Wait, collaboration, and subagent actions show their exact completed or failed outcome when Codex supplies one; genuinely ambiguous results remain unknown.
Why This Change Was Made
The fix restores the existing fact precedence at both owners:
Script completed/Script failedenvelopes now apply to Wait as well as Exec; yielded and unrecognized envelopes stay unknown.No fallback, config, protocol, or persistence surface is added. Production delta is +14 net lines in the Codex projector and net zero in Control UI; tests add +182 net lines across the two owner boundaries.
Evidence
Before, the active tool row incorrectly says Outcome unknown:
After, the identical history and live event say Running:
Pre-fix proofs failed for the intended reasons:
Running, receivedOutcome unknownrunning, receivedunknownPost-fix validation:
OPENCLAW_VITEST_MAX_WORKERS=1 pnpm test extensions/codex/src/app-server/event-projector.output-fidelity.test.ts ui/src/pages/chat/components/chat-tool-cards.node.test.ts ui/src/pages/chat/components/chat-tool-cards.test.ts— 89 passed across two routed shardsnode scripts/check-changed.mjs— passed the full changed typecheck, lint, ratchet, dead-export, boundary, and import-cycle plan.agents/skills/autoreview/scripts/autoreview --mode branch --base origin/main --max-priority P2— no accepted/actionable findingsCodex contract checked directly in
../codexat exact tagrust-v0.160.0: collaboration statuses includeinterrupted; app-server native items retain same IDs across start/completion notifications.Test cost
One-worker local wall times on rebased head
feda0718748572c759f2ca08578fa841811135b1:Exact-head CI run 37151725724 completed successfully in 485 seconds (8m 05s).