Repository navigation
improve: prove Codex auth migration product flow - #109291
Conversation
d8f6122 to
1b779ef
Compare
399fdd8 to
611a7bd
Compare
611a7bd to
b8d800f
Compare
|
Codex review: needs maintainer review before merge. Reviewed July 16, 2026, 7:50 PM ET / 23:50 UTC. Summary PR surface: Tests +624, Other -25. Total +599 across 15 files. Reproducibility: not applicable. This PR improves regression proof rather than fixing a reported current-main failure, and its exact-head evidence exercises the intended product paths. Review metrics: 1 noteworthy metric.
Stored data model Merge readiness Overall follows the weaker of proof and patch quality, so missing proof can cap an otherwise strong patch. Next step before merge
Security Review detailsBest possible solution: Keep the product-backed QA scenarios and shared App Server fixture, then land them after ordinary owner review confirms the fixture remains aligned with the pinned Codex protocol revision. Do we have a high-confidence way to reproduce the issue? Not applicable: this PR improves regression proof rather than fixing a reported current-main failure, and its exact-head evidence exercises the intended product paths. Is this the best way to solve the issue? Yes. Replacing fixture-parity assertions with bounded product-backed doctor, SQLite, Gateway, and App Server flows is the narrowest maintainable way to prove the existing auth-migration contract. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against 05980207c6a4. Label changesLabel changes:
Label justifications:
Evidence reviewedPR surface: Tests +624, Other -25. Total +599 across 15 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
|
Give the status CLI its own instance-owned app-server log. The running Gateway keeps its original environment and can continue catalog discovery without being mistaken for a usage account read or response with the same numeric request ID. Restore the CLI environment on settlement. Preserve the product-proof contract from #109291: every login payload, ordering, identity response, migration and recovery assertion, and all existing timeouts. Co-authored-by: Dallin Romney <[email protected]>
Give the status CLI its own instance-owned app-server log. The running Gateway keeps its original environment and can continue catalog discovery without being mistaken for a usage account read or response with the same numeric request ID. Restore the CLI environment on settlement. Preserve the product-proof contract from openclaw#109291: every login payload, ordering, identity response, migration and recovery assertion, and all existing timeouts. Co-authored-by: Dallin Romney <[email protected]>
What Problem This Solves
The QA catalog claimed Codex auth-profile migration coverage through fixture-only lifecycle oracles. Those rows did not prove that
openclaw doctor --fixrepaired the real persisted store, that the selected OAuth profile reached Codex App Server, or that a production Gateway turn and account read completed.Why This Change Was Made
This retargets both owned auth scenarios to native product-backed Vitest flows. The tests run the real doctor command, inspect canonical per-agent SQLite state, execute a Codex-backed Gateway turn, verify durable
chat.history, and exercise the production status/usage handoff through an upstream-shaped App Server fixture. The auth proof reuses the existing incremental JSONL tailer and Gateway client helper; both Codex fixtures now share one App Server transport/thread-response builder instead of maintaining parallel protocol copies.AI-assisted: yes. The implementation was reviewed with the repository autoreview workflow and all actionable findings were resolved.
User Impact
There is no runtime behavior change. Maintainers now get honest regression proof for legacy Codex OAuth migration, mixed-profile selection, completed Gateway execution, and the Codex account handoff instead of fixture-parity assertions.
Evidence
b8d800f50142eaee157b0a448afca45ec08bcbb9: fresh Blacksmith Testboxtbx_01kxpfpkxy7k7jc43ap8aey0xppassed repository-wideoxfmt --checkacross 22,760 files, all core/extension/root test-type projects, and the overlapping QA catalog 43/43. The byte-identical task commit was then rebased conflict-free onto the canonical blocker-fix base with stable patch ID5a39495f204f11c4a5c85f1c8a8ec8e69eee9782and an equalgit range-diff.check:changedpassed all-project typecheck, full core/extensions/scripts lint, formatting, dependency/boundary/migration guards, and runtime import-cycle checks.openai:qa-oauth, preserved canonical order and OAuth refresh/expiry fields, removed legacy JSON, completedQA_CODEX_AUTH_PRODUCT_PROOF_OKthrough Gateway history, then emittedaccount/login/startbeforeaccount/readwith{}and the upstream ChatGPT account response shape.waitForAssistantHistoryconcurrently checks every returned session key on every poll with bounded request timeouts and retainsdeliver: falseproduction Gateway history proof.new URL(..., import.meta.url)reference and both fixtures import the shared App Server helper; production and full-tree unused-file scans report zero entries.019f6cdb-ac02-7db2-9837-802cc47f4bd5): clean, no accepted/actionable findings, confidence 1.a70d583f2461a0313735d3e0331b9eafd1931a7b, including canonical cleanup squash1f5299da7e1636c625e3f77790fedb2deee5f78f; the docs-sync declaration is singular and the product-backed scenario routing and fixture resolver mapping are preserved.openai/codex@2e1607ee2fa8099a233df7437adee5f16a741905, especiallycodex-rs/app-server-protocol/src/protocol/v2/account.rs:500,thread.rs:170,turn.rs:166,turn.rs:395, anditem.rs:1304.