Skip to content

test(codex): align startup-retry and media fixtures with current contracts - #172947

Merged
steipete merged 1 commit into
mainfrom
test/codex-red-main-fixtures
Oct 15, 2026
Merged

steipete merged 1 commit into
mainfrom
test/codex-red-main-fixtures

Conversation

@steipete

@steipete steipete commented Oct 15, 2026 •

Copy link
Copy Markdown
Contributor

What Problem This Solves

Repairs latent red main exposed by PR #172381's CI run 38696213621: two existing Codex test files retained assumptions from before intentional production contract changes.

User Impact

No production behavior changes. Codex regression coverage again exercises the intended overload and bounded-media contracts.

Why This Change Was Made

  • 73c9e39c619a (fix(codex): recover failed conversations while sibling work continues #172287) made managed local resumes require confirmed thread unloading. The startup-retry fixture now reports notLoaded when reading the thread, allowing the test to reach its native overload response. The exact -32001 error, unchanged binding, healthy shared client, and single-process assertions remain intact; missing-unload coverage remains with the lifecycle tests.
  • 14eee3444e39 (fix: keep Codex commands on the selected GitHub identity #171218) disables native shell features when native code mode is disabled. Both bounded-media request expectations now include features.shell_tool: false and features.unified_exec: false, preserving complete request equality.

The managed-unload interpretation was checked against the pinned Codex lifecycle source.

Evidence

Exact-head CI run 38707206591, attempt 1 succeeded on 0c93cac3af44929c83bb579e4992112d20b90451.

The changed-extension job confirms:

  • extensions/codex/src/app-server/attempt-startup-retry.test.ts: 9/9 passed, including the exact overload/shared-client/binding case; 52.45 seconds Vitest duration.
  • extensions/codex/media-understanding-provider.test.ts: 15/15 passed, including both complete bounded-turn config comparisons; 28.82 seconds Vitest duration.

Test types, typed extension lint, general lint, planner checks, boundaries, and baseline ratchets also passed. No inherited-failure exception was needed.

Changed-file static oxlint with the repository configuration, oxfmt, and git diff --check passed locally. Independent P0-P2 autoreview completed scoped-clean with no actionable findings. The local typed-lint wrapper timed out during plugin declaration generation after 300 seconds; the successful CI lint supplies that proof.

Earlier local baseline attempts on an overloaded host failed before the reported assertions: startup retry had seven passes and two initialization/startup timeouts; both selected media cases reached their existing 120-second timeout. Those attempts are not claimed as reproductions of the reported CI signatures. PR CI was explicitly selected for test validation and proves both repaired files above.

73c9e39 (#172287) requires confirmed unloading before managed
thread resume. Report an unloaded thread in the startup fixture so the
exact overload error and binding/shared-client preservation checks run.

14eee34 (#171218) disables native shell features alongside code mode.
Include both flags in the complete bounded-media request expectations.

Repair latent red-main failures exposed by PR #172381, CI run 38696213621.
Static oxlint, oxfmt, whitespace checks, and isolated P0-P2 review pass.
Test and typed-lint proof use PR CI because local preparation timed out.
@clawsweeper

clawsweeper Bot commented Oct 15, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

Pull request received. I will update this pull request when review starts.

ClawSweeper review complete

ClawSweeper finished reviewing this revision. The review result is being finalized.

View the workflow run.

@steipete
steipete marked this pull request as ready for review October 15, 2026 08:39
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 15, 2026 •

Copy link
Copy Markdown
Contributor

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-15T08:41:32.084743Z 0c93cac Draft marked ready
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@clawsweeper clawsweeper Bot added P2 Normal backlog priority with limited blast radius. rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. labels Oct 15, 2026
@clawsweeper

clawsweeper Bot commented Oct 15, 2026

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge.

What this changes

This PR updates Codex startup and media tests to match confirmed thread unloading and disabled native shell features.

Example: A resumed thread returns RPC error -32001 while another lease uses the shared client.

  • Before: The fixture reports an idle thread, preventing the test from reaching the intended overload rejection.
  • After: The fixture reports notLoaded, allowing the existing overload, binding-preservation, and shared-client assertions to run.

Review scores

Measure Result What it means
Overall readiness 🦐 gold shrimp (3/6) A focused, source-verified test repair with successful exact-head CI; available behavioral evidence remains fixture-based.
Proof confidence 🦐 gold shrimp (3/6) This maintainer-authored, test-only PR changes fixture state and protocol expectations; exact-head CI and the changed-extension job succeeded, with no production behavior requiring a separate live demonstration.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Product

Kind: Test only · Worth it: Yes · Fix scope: Complete
User problem: Maintainers encounter Codex test failures caused by fixtures that lag intentional runtime contracts.
Reason: The narrow repair restores meaningful coverage while preserving the intended isolation and error-handling contracts; the supplied maintainer-authorship context establishes direction.

Merge readiness

✅ Ready for maintainer review

Keep this PR open: it repairs stale Codex fixtures without weakening their assertions or changing production behavior, and exact-head CI succeeded; no actionable defects were found.

Priority: P2
Reviewed head: 0c93cac3af44929c83bb579e4992112d20b90451

Before merge

None.

Findings

None.

Tests

  • Missing end-to-end proof: The cited pre-fix CI failure trace could not be inspected because log downloads are blocked; this test-only repair needs no additional shipped-entry-point demonstration.
Agent review details

How this fits together

The Codex plugin converts agent and media requests into app-server RPC calls; these tests exercise startup lifecycle behavior and bounded media request configuration.

flowchart LR
  A[Agent request] --> B[Startup lifecycle]
  B --> C[Codex RPC client]
  D[Media request] --> E[Bounded turn configuration]
  E --> C
  C --> F[App server fixture]
  F --> G[Contract assertions]
Loading

Technical review

Best possible solution:

Merge the focused fixture repair while preserving the existing production contracts and negative lifecycle coverage.

Do we have a high-confidence way to reproduce the issue?

Source inspection establishes both mismatches: media request equality omits emitted shell-disable flags, and the startup fixture never confirms unloading before the intended overload response; no tests were run during this read-only review.

Is this the best way to solve the issue?

The repair changes the fixture producer and independent protocol expectations without bypassing the unload guard, loosening equality, or altering production code.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning medium; reviewed against 9b2bc0ed7e13.

Provenance checked

  • Startup overload fixture keeps the original intent (3254b7f: The startup fixture originally exercised retry and refusal behavior; subsequent lifecycle changes require confirmed unloading before managed resume.)
  • Bounded media request expectations keeps the original intent (2602362: Complete request comparisons preserve bounded-worker isolation; adding the already-emitted shell-disable flags retains that purpose.)

Testing

Proof path: in-process harness.

Security

None.

Evidence

What I checked:

Likely related people:

  • Peter Steinberger: Raw commit 9bdad16 adds extensions/codex/src/app-server/attempt-startup-retry.test.ts:82 relative to its recorded parents. This identifies author metadata, not feature responsibility or a PR merger. (role: source-line author; confidence: high; commits: 9bdad160d806; files: extensions/codex/src/app-server/attempt-startup-retry.test.ts)
  • Vincent Koc: Raw commit 2602362 adds extensions/codex/media-understanding-provider.test.ts:325 relative to its recorded parents. This identifies author metadata, not feature responsibility or a PR merger. (role: source-line author; confidence: high; commits: 26023626be0a; files: extensions/codex/media-understanding-provider.test.ts)

PR surface

Tests +6. Total +6 across 2 files. Added test files: 0.

View PR surface stats
Area Files Added Removed Net
Source 0 0 0 0
Tests 2 6 0 +6
Docs 0 0 0 0
Config 0 0 0 0
Generated 0 0 0 0
Other 0 0 0 0
Total 2 6 0 +6

Labels

Label changes:

  • add P2: Stale fixtures break useful Codex validation, with no production behavior change or immediate user outage.
  • add rating: 🦐 gold shrimp: Overall readiness is 🦐 gold shrimp; proof is 🦐 gold shrimp and patch quality is 🐚 platinum hermit.
  • add status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR.

Label justifications:

  • P2: Stale fixtures break useful Codex validation, with no production behavior change or immediate user outage.
  • rating: 🦐 gold shrimp: Overall readiness is 🦐 gold shrimp; proof is 🦐 gold shrimp and patch quality is 🐚 platinum hermit.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR.

Rating scale

6/6 🦀 challenger crab · 5/6 🦞 diamond lobster · 4/6 🐚 platinum hermit · 3/6 🦐 gold shrimp · 2/6 🦪 silver shellfish · 1/6 🧂 unranked krab. Overall follows the weaker of proof and patch quality; ✨ marks media proof (a screenshot, video, or linked artifact) that directly shows the changed behavior.

Workflow

ClawSweeper edits this one comment on every review. Comment @clawsweeper re-review for a fresh review only. Repair and merge execution lanes are retired.

Reviewed October 15, 2026, 5:04 AM ET / 09:04 UTC.

@steipete
steipete merged commit 7023f6c into main Oct 15, 2026
180 of 181 checks passed
@steipete
steipete deleted the test/codex-red-main-fixtures branch October 15, 2026 09:15
@steipete

Copy link
Copy Markdown
Contributor Author

Merged via squash.

github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Oct 16, 2026
…172947)

96ccbf0 (openclaw#172287) requires confirmed unloading before managed
thread resume. Report an unloaded thread in the startup fixture so the
exact overload error and binding/shared-client preservation checks run.

323baf4 (openclaw#171218) disables native shell features alongside code mode.
Include both flags in the complete bounded-media request expectations.

Repair latent red-main failures exposed by PR openclaw#172381, CI run 38696213621.
Static oxlint, oxfmt, whitespace checks, and isolated P0-P2 review pass.
Test and typed-lint proof use PR CI because local preparation timed out.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

extensions: codex P2 Normal backlog priority with limited blast radius. rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. size: XS status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant