Skip to content

test(codex): use shared Windows attest spawn budgets - #7151

Merged
lidge-jun merged 2 commits into
devfrom
fix/windows-attest-zero-effect-timeout
Oct 15, 2026
Merged

lidge-jun merged 2 commits into
devfrom
fix/windows-attest-zero-effect-timeout

Conversation

@lidge-jun

@lidge-jun lidge-jun commented Oct 15, 2026 •

Copy link
Copy Markdown
Owner

Summary

  • Fix the Windows x64 zero-effect attest test's hardcoded 15-second child deadline by using the repository's existing COLD_SPAWN_BUDGET_MS for the first Node → Bun/native-reader launch and SPAWN_BUDGET_MS for the following bare attest. Each child deadline leaves 5 seconds inside its matching outer test budget. Only these two Windows-only cases change; all report, state-preservation, redaction and non-execution assertions remain intact.
  • Evidence: dev run 38697651428, Windows 7/9 failed at spawnSync node ETIMEDOUT after 15029.18ms. The following bare attest completed in 4604.28ms. The previous nine dev manual runs all passed this case, with explicit attest consistently slower than bare attest:
Dev manual run Explicit attest (ms) Bare attest (ms)
38510591342 2524.17 664.38
38507644375 6198.19 493.78
38503986851 4244.08 675.10
38499932279 2537.09 673.40
38319543073 2154.20 761.14
38312630127 3325.92 620.05
38250055508 1460.55 640.33
38214884055 1738.56 693.45
38162375606 2083.05 644.91
  • Historical attempts were also checked. Repeated timestamp/result lines carried into later attempts were counted once. Run 38510591342 attempt 1 stopped at an unrelated failure in batch 10/48 before this case; its observed attest result is from attempt 2. Across all retained attempts there are ten distinct timestamped attest observations and only the reported timeout. The table describes case outcomes, not overall workflow success.

  • Diagnosis: the test bypassed the shared spawn-budget policy while measuring an intrinsic real-process/native-reader boundary. bin/ocx.mjs gates boot restore and calls resolveBun({ allowInstall: false }) for this namespace; shim auto-restore is excluded by src/cli/codex-shim-autorestore.ts. Explicit identity inspection uses two bounded local held-handle snapshots in src/codex/cli-installation-identity.ts and src/codex/windows-installation-files.ts, with no candidate execution, npm/registry calls, PowerShell or recursive scan. No avoidable product work was identified. The first-versus-next timings and slowdown in both cases support cold Windows execution/runner contention; existing logs do not isolate module loading, FFI or filesystem/driver scheduling, so a specific Defender cause is not claimed. This sample contains one timeout in ten case executions, counting only one occurrence per job even when the failure is repeated in its summary.

Verification

  • bun test tests/codex-integration/codex-cli-update-zero-effect.test.ts tests/codex-integration/codex-cli-update-launcher-policy.test.ts tests/codex-integration/codex-cli-installation-identity.test.ts tests/codex-integration/codex-cli-installation-targets.test.ts tests/codex-integration/codex-cli-windows-installation-files.test.ts — 44 pass, 13 existing platform skips, 0 fail, 110 assertions on macOS.
  • After initializing the lockfile-pinned Bun dependency's postinstall, bun test tests/codex-integration/codex-cli-update-zero-effect.test.ts — 3 pass, 2 existing Windows-only skips, 0 fail, 21 assertions.
  • bun run typecheck — passed.
  • bun run structure:check — passed.
  • git diff --check — passed.
  • Full local suite NOT RUN: the task explicitly restricts local execution to targeted files, typecheck and structure checks because of shared-worktree resource contention. Windows native execution is not available locally; exact-head hosted CI is the required platform validation. No new skips, retries, dependencies, workflow policy or production behavior changes.
  • Hosted status at 2026-10-15 09:20 UTC, head f6165872062ff370613a6a9f5ea36320b7d4de17: PR CI run 38701244611 remains queued, with select windows runner and changes both unstarted. Monitored roughly every five minutes from 07:49 to 09:19 UTC (the authorized 90-minute bound). Latest metadata checks are also queued. A superseded label run was cancelled automatically after the PR description was edited; it is not passing evidence. Codex reports its review completed without posted findings; CodeRabbit did not review because of its usage limit.
  • Full lane=all workflow dispatch NOT RUN: the requested prerequisite, green PR checks, was not reached within the polling bound. Windows execution remains unverified. No CI reruns or bypasses were used. Next authorized step after PR CI turns green: gh workflow run ci.yml --ref fix/windows-attest-zero-effect-timeout -f lane=all, then inspect that exact-head dispatch and its Windows 7/9 case timings.

Checklist

  • Scope stays focused and avoids unrelated cleanup.
  • Docs or release notes were updated when needed. Test-only budget alignment; product contract is unchanged.
  • Security-sensitive changes were reviewed for secrets, auth, and unsafe defaults. No security-sensitive product changes; existing zero-effect and output-redaction checks remain intact.

@lidge-jun
lidge-jun requested a review from Ingwannu as a code owner October 15, 2026 07:48
@coderabbitai

coderabbitai Bot commented Oct 15, 2026

Copy link
Copy Markdown
Contributor

Warning

Review limit reached

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

Next included review available in 33 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used all 10 included reviews currently available.

Learn how review limits work.

Review configuration:

⚙️ Run configuration
  • Configuration used: Repository: lidge-jun/opencodex/.coderabbit.yaml
  • Review profile: ASSERTIVE
  • Plan: Advanced
  • Run ID: 3ec7b0ce-54b4-46b4-b921-1a7264545928
📥 Commits

Reviewing files that changed from the base of the PR and between 7640a94 and f616587.

📒 Files selected for processing: 1
  • tests/codex-integration/codex-cli-update-zero-effect.test.ts
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@chatgpt-codex-connector

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

Copy link
Copy Markdown

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-15T07:50:48.981859Z f616587 PR opened
ℹ️ 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.

@github-actions

Copy link
Copy Markdown
Contributor

✅ Deterministic PR hygiene checks passed.

@github-actions github-actions Bot added the chore Maintenance, CI, tests, refactors, or build changes (not a user-facing bug or feature). label Oct 15, 2026
@lidge-jun

Copy link
Copy Markdown
Owner Author

Maintainer integration into dev (MAINTAINERS.md dev maintainer-integration policy; batch integration authorized by @lidge-jun on 2026-10-15).

  • Head: 132139f13017cd2fec06b190ac3639e4542632a2 (tree 95c50d92a621e45be9b4a7798b7c7b125f9150c9) = this branch merged with origin/dev ee6cbe23a7.
  • Exact-head evidence: GitHub-hosted Actions for this account have not been assigning runners since 2026-10-15 13:30 UTC, so by owner decision the evidence is a full bun run test (Bun 1.4.3 test runner, root and GUI dependencies installed, GUI built) of this exact tree on a maintainer host (macOS arm64): exit 1, 9 min, 4 failing test(s), each also failing in the same host's baseline run of dev 60bf4c7 (environment-only): a secondary ensure parent preserves shared Grok, Codex and Claude agent bytes, connected Desktop uses hub IDs across a cold restart (stored profile=false), live audio readiness and bounded closure > native open and non-readiness events cannot cla, update stops the running proxy before replacing files > npm launcher restarts the stopped .
  • Local gates on the same tree: bun run typecheck, file-size ratchet, test-layout and structure:check.
  • Hosted CI checks for this head may still be queued; they are not claimed as evidence.

@lidge-jun
lidge-jun merged commit bca6184 into dev Oct 15, 2026
3 checks passed
@lidge-jun
lidge-jun deleted the fix/windows-attest-zero-effect-timeout branch October 15, 2026 16:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

chore Maintenance, CI, tests, refactors, or build changes (not a user-facing bug or feature).

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant