Repository navigation
test runtime: the source control generation pipe-close test runs on Node (orca #48, slice 9) - #59
Merged
nachumi-a2zoperations merged 1 commit intoNov 16, 2026
Conversation
…ode (orca #48, slice 9) Root cause of source-control-wsl-prompt.test.ts ("runs the production attempt through real private shell preparation and pipe-close") failing on Bun only: the fixture child closes its stdin (exec 0<&-), the production code writes the prompt into that pipe, and the test proves it exercised the pipe-close path by seeing the stdin stream emit 'error' with EPIPE. Probed outside Orca (bun 1.4.4 vs Node): Node's stream emits EPIPE; Bun's write() returns false and emits no error. The product is not affected, on any runtime it uses: - it does not depend on that error event: the prompt producer waits for the stream's 'close', and the runner for the child's close/exit. Under Bun its own assertions in this test passed (result not successful, the private directory removed once); only the test's EPIPE observation failed; - this code runs only in Electron main (Node). The daemon and the orcad server do not bundle text generation, and orcad slots now run a pinned Node (Bun survives only as a "Bun-era" slot marker). Fix: route this test to the Node runtime (vitest-node-runtime-files .mjs, placed mid-list so it does not touch the lines PR 58 adds). The routing check is its own small test file for the same reason. No product code changes. Tests: vitest-node-runtime-pipe-errors.test.mjs, red first, green now; it + source-control-wsl-prompt through the normal runner: 43/43 (1 was red). Refs #48
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Refs #48 (slice 9:
source-control-wsl-prompt.test.ts, 1 red test on Bun). #48 stays open for the rest.Root cause
The test "runs the production attempt through real private shell preparation and pipe-close" starts a child that closes its own stdin (
exec 0<&-). The production code then writes the prompt into that pipe, and the test proves it exercised the pipe-close path by seeing the stdin stream emiterrorwithEPIPE.write()returns false, thenerrorwithcode = EPIPEwrite()returns false, no error event at allThe product is not affected, on any runtime it uses
close, and the runner for the child'sclose/exit. Under Bun, the product's own assertions in this test passed (result not successful, the private directory removed once). Only the test'sEPIPEobservation failed.orcadserver bundles text generation, andorcadslots now run a pinned Node. Bun survives only as a "Bun-era" slot marker inorcad-artifacts.ts.Fix
Route this test to the Node runtime in
vitest-node-runtime-files.mjs. Product code is unchanged.git merge-treeagainst PR 58's head is clean.Tests
vitest-node-runtime-pipe-errors.test.mjs: red first, green now.source-control-wsl-prompt.test.tsthrough the normal runner: 43/43 (1 was red).check-changed: 13/13.