Repository navigation
perf(tests): reuse cached CLI for Windows prompt fixtures - #2195
Alan-TheGentleman merged 3 commits into
Conversation
Avoid rebuilding the same CLI for trusted-pin fixtures while preserving caller-owned executable paths. Pin build elision, byte identity, isolation and cached lifetime with a regression. Refs Gentleman-Programming#2193
|
No actionable comments were generated in the recent review.
|
| Layer / File(s) | Summary |
|---|---|
Copy and validate the cached fixture plugin/codex_windows_user_prompt_test.go |
buildCodexWindowsEngram copies the cached CLI fixture to the requested target. Tests use the updated helper signature and verify distinct copies, unchanged fixture bytes, caller-owned files, and working directory. |
Estimated code review effort: 2 (Simple) | ~10 minutes
Change: Other
Suggested reviewers: gentleman-programming
Merge Risk: 
Minimal · up to f3c24
-
No merge-blocking issue was established; the cached fixture remains available throughout the test run.
Pre-merge checks: 
3 · 
1
-
Failed checks: 1 warning Passed checks: 3 passed-
Full details: Linked Issues check
-
Explanation
Issue
#2193requires reuse only for equivalent CLI fixtures and preservation of private paths, isolation, trusted-path behavior, cleanup, and lifetime. Inplugin/codex_windows_user_prompt_test.go,buildCodexWindowsEngramnow obtainsbuildCodexFixtureCLIand copies its bytes to each requested target.TestCodexWindowsEngramPrivateCopyReusedchecks separate space-containing executable paths, byte equality, cached-file survival, non-aliasing, caller-owned files, and working-directory isolation. The native tests retain their existing assertions and identities. The reported tests provide build-count and functional evidence. The PR does not claim that reuse fixes the package timeout or HTTP timing failure.
-
Full details: Out of Scope Changes check
-
Explanation
The whole-PR diff contains unrelated race-cache workflow work. It changes
.github/workflows/ci.yml, addsdocs/ci-go-race.mdcontent for#2192, and modifies.github/scripts/ci-technical-contracts.test.mjs,.github/scripts/ci-unit-node.test.mjs, and the workflow baseline hash. These changes implement CI cache policy and contract testing, not Windows Codex fixture reuse for#2193. The current PR description and linked issue define a narrow test-helper scope.Resolution
Remove the unrelated race-cache workflow, documentation, contract-test, and baseline changes from this pull request, or move them to a separately linked and authorized pull request. Retain the
plugin/codex_windows_user_prompt_test.gochanges for#2193.
-
Finishing Touches
-
🧪 Generate unit tests (beta)
-
- Create a new PR
-
- 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.
Comment @coderabbitai help to get the list of available commands.
…gramming#2194) * ci(race): refresh compatible Go caches on trusted main Refresh immutable cache populations by tested revision while retaining one Race cache owner and full suites. Restrict workflow saves to successful canonical main pushes. Hosted net benefit remains unproven. Refs Gentleman-Programming#2192. * test(ci): refresh approved Race workflow baseline Accept only the independently verified Race cache delta in the pinned CI baseline. Retain full-file hashing, readiness guards and every other workflow hash. Refs Gentleman-Programming#2192.
|
Focused native Windows qualification completed for this exact head (
Run: https://github.com/Alan-TheGentleman/engram-ci-qualification-01a19147/actions/runs/41229358002 Both snapshots ran on the same native Windows x64 image Limit: this is one focused comparison with extra candidate regression coverage, not proof that the complete Windows suite is green or a full-CI latency guarantee. The existing observational failure and its original 600-second/HTTP budgets remain visible and unchanged. All canonical required contexts and the merge queue remain mandatory; this auxiliary run does not impersonate a required check. No source, approval, label or guard was weakened. No human responsibility attestation is inferred. Post-merge observation — global Windows qualification remains openThe mandatory native queue merged the qualified head as Exact-main run: https://github.com/Gentleman-Programming/engram/actions/runs/41230813688
No retry, gate/label/rules change, timeout increase, source fix or reduced security assertion was used to obtain this result. The fixture optimization and normal delivery are observed; a green complete Windows suite remains unproven and outside this focused qualification's outcome. The remaining Windows debt needs explicit disposition rather than being silently declared fixed. Final canonical main verification — Windows repair completeBoth complementary source PRs merged through the mandatory native queue at
The final canonical tree Post-merge exact-main CI: https://github.com/Gentleman-Programming/engram/actions/runs/41245230929 All 17 jobs succeeded. Final native Windows JSON independently checked against the qualified inventory: 8603 PASS / 127 unchanged SKIP / 0 FAIL, 8730 unique paths, original exit0, no missing/extra cases, changed outcomes, duplicates or unfinished tests. All 38 package outcomes match (34 passed, four have no tests). Exact checkout Production, workflow, native1.5s deadline, public2s assertion, package10m budget and all executable/path/ownership guards remain unchanged. No filtering, new skip, forced success, status substitution, or required-check/queue/settings change was needed. Earlier failed baseline/local checks remain failed historical evidence; final green is an observed result at this exact source, not a claim that every intermittent failure was explained or a stable whole-CI speed guarantee. The wider #1891 required-check rollout is not activated or closed by this repair. |
f616a7e
🔗 Linked Issue
Closes #2193
Lifecycle Evidence
🏷️ PR Type
type:bugtype:featuretype:questiontype:docstype:refactortype:choretype:breaking-change📝 Summary
📂 Changes
plugin/codex_windows_user_prompt_test.go🧪 Test Plan
go test ./plugin -json -count=1 -run "^(TestCodexWindowsEngramPrivateCopyReused|TestCodexFixtureCLIReused)$"— passed.go test ./plugin -json -count=1 -run "^(TestCodexWindowsNativeUserPrompt.*|TestCodexWindowsSessionEndAdapter|TestCodexWindowsEndEnvPortIsolation|TestCodexWindowsEngramPrivateCopyReused|TestCodexFixtureCLIReused)$"— 13 top-level tests / 50 passing records.go test ./plugin -json -count=1, withOS=Windows_NT, installed Git/jq and isolated profile/cache/temp — final uninstrumented run: 542 PASS, 0 FAIL, 6 SKIP. Those six platform/prerequisite exclusions are not executed coverage.🤖 Automated Checks
Local evidence is not a hosted pass. All statuses below are pending at creation.
✅ Contributor Checklist
Closes #N.type:*label in this separately authorized creation request.Co-Authored-Bytrailer.💬 Notes for Reviewers
Base:
a6f66c2ea21f6ec2fcec4b4d6d54c576bb069897; head:0b181d6a2f7f0aebc222d2a42f6ee1e865685a9e(73 additions / 8 deletions).A prior local runner omitted
OS=Windows_NT, selected the POSIX background branch and hit the existing pipe-EOF deadline. An isolated two-case diagnostic confirmed the environment distinction; the final package run used the correct Windows environment without instrumentation or source/assertion/deadline changes. Prior failures were preserved, not relabeled.This changes tests only, not production hooks/APIs/cache ownership. Eliminating redundant compilation does not establish hosted Windows/full-CI speedup. Native assessment was medium with reviewDue=false; independent verification is not a fabricated native approval.
Risk: item 2 (fixture executable/path trust), item 4 (shared fixture lifetime). No merge or manual CI dispatch/rerun is authorized.
Summary by CodeRabbit
Current-main verification
Current candidate: f3c247d, integrated with canonical main 7cf4ed2 without rewriting existing history. Original one-file scope retained.
Native Windows Go 1.26.10: go test -mod=readonly ./plugin -run '^TestCodexWindows(EngramPrivateCopyReused|NativeUserPromptTrustedPinForwardsInputAndMeetsTimingBudget|NativeUserPromptIgnoresInterpreterAndBinaryHijacks)$' -count=1 -timeout=2m -v passed (18.438s). All three named tests passed, preserving private independent executable copies, existing native timing assertions and hostile-executable rejection. No deadline, skip allowance or production behavior changed.
Fresh current-head hosted CI and review remain pending. This does not repair every Windows full-suite failure, prove global package savings independently, or activate the required-check rollout.