Repository navigation
[node] Inherit CommonOptions in ForkOptions to support windowsHide - #75525
Conversation
Extend CommonOptions as suggested in discussion DefinitelyTyped#75523 so fork accepts windowsHide without a local intersection type. Apply the same correction to the latest, v22, v24, and v25 definitions and exercise both overloads. Package checks pass for all four versions. A compiled runtime example preserves stdout, IPC, and successful exit with hidden forked workers. Co-authored-by: Codex <noreply@openai.com>
|
🔔 @microsoft @jkomyno @r3nya @btoueg @Touffy @mohsen1 @galkin @eps1lon @WilcoBakker @chyzwar @trivikr @yoursunny @qwelias @ExE-Boss @peterblazejewicz @addaleax @victorperin @nodejs @LinusU @wafuwafu13 @mcollina @Semigradsky @Renegade334 @anonrig — please review this PR in the next few days. Be sure to explicitly select |
Describe the existing windowsHide option and its false default alongside the other fork options, using the wording already documented for spawn. Refs: DefinitelyTyped/DefinitelyTyped#75525 Signed-off-by: christopher-buss <christopher.buss+github@protonmail.com> Assisted-by: Codex Co-authored-by: Codex <noreply@openai.com> PR-URL: #65887 Reviewed-By: Xuguang Mei <meixuguang@gmail.com> Reviewed-By: Stefan Stojanovic <stefan.stojanovic@janeasystems.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
|
The doc change was merged into node if this helps at all :) |
|
@christopher-buss: Everything looks good here. I am ready to merge this PR (at 1d8eb21) on your behalf whenever you think it's ready. If you'd like that to happen, please post a comment saying:
and I'll merge this PR almost instantly. Thanks for helping out! ❤️ (@microsoft, @jkomyno, @r3nya, @btoueg, @Touffy, @mohsen1, @galkin, @eps1lon, @WilcoBakker, @chyzwar, @trivikr, @yoursunny, @qwelias, @ExE-Boss, @peterblazejewicz, @addaleax, @victorperin, @nodejs, @LinusU, @wafuwafu13, @mcollina, @Semigradsky, @Renegade334, @anonrig: you can do this too.) |
e839b8f
into
DefinitelyTyped:master
Describe the existing windowsHide option and its false default alongside the other fork options, using the wording already documented for spawn. Refs: DefinitelyTyped/DefinitelyTyped#75525 Signed-off-by: christopher-buss <christopher.buss+github@protonmail.com> Assisted-by: Codex Co-authored-by: Codex <noreply@openai.com> PR-URL: #65887 Reviewed-By: Xuguang Mei <meixuguang@gmail.com> Reviewed-By: Stefan Stojanovic <stefan.stojanovic@janeasystems.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Describe the existing windowsHide option and its false default alongside the other fork options, using the wording already documented for spawn. Refs: DefinitelyTyped/DefinitelyTyped#75525 Signed-off-by: christopher-buss <christopher.buss+github@protonmail.com> Assisted-by: Codex Co-authored-by: Codex <noreply@openai.com> PR-URL: #65887 Reviewed-By: Xuguang Mei <meixuguang@gmail.com> Reviewed-By: Stefan Stojanovic <stefan.stojanovic@janeasystems.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com>

fork()rejectswindowsHidein TypeScript even though Node forwards the option tospawn()and uses it when creating cluster workers. MakeForkOptionsextendCommonOptions, as suggested in discussion #75523.Apply the same one-line correction to the latest, v22, v24, and v25 definitions. Existing child-process tests now exercise
windowsHidewith both fork overloads and retain coverage oftimeout.windowsHide: true; stdout, IPC messages, and exit status were preserved.windowsHidebefore the declaration change.pnpm test <package to test>. Passedpnpm test node,pnpm test node/v22,pnpm test node/v24, andpnpm test node/v25across their supported TypeScript configurations.For this existing definition:
windowsHideto fork.Repository-wide
test-allwas not run; local validation was scoped to the Node packages in a sparse checkout.Generated with Codex.