build,test: increase stack size limit on Windows#43632
Merged
nodejs-github-bot merged 1 commit intonodejs:mainfrom Jul 2, 2022
Merged
Conversation
Collaborator
|
Review requested:
|
598a8eb to
88fc47b
Compare
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
bnoordhuis
approved these changes
Jun 30, 2022
This comment was marked as outdated.
This comment was marked as outdated.
gengjiawen
approved these changes
Jul 1, 2022
Collaborator
Collaborator
|
Landed in 71691e5 |
23 tasks
guangwong
pushed a commit
to noslate-project/node
that referenced
this pull request
Oct 10, 2022
Fixes: nodejs/node#43630 PR-URL: nodejs/node#43632 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: Jiawen Geng <technicalcute@gmail.com>
sbc100
added a commit
to sbc100/emscripten
that referenced
this pull request
Dec 2, 2023
On windows the default stack size is still limited to 1MB in older versions of node. See nodejs/node#43632 which made it into v19.0.0. Fixes: emscripten-core#17897
sbc100
added a commit
to emscripten-core/emscripten
that referenced
this pull request
Dec 4, 2023
On windows the default stack size is still limited to 1MB in older versions of node. See nodejs/node#43632 which made it into v19.0.0. Fixes: #17897
tniessen
added a commit
to tniessen/node-pqclean
that referenced
this pull request
Mar 7, 2024
All supported Node.js release lines have increased the stack size on Windows, so it is no longer necessary to use WebAssembly to access certain algorithms on Windows. Refs: nodejs/node#43632
data-wardenb6ym
added a commit
to data-wardenb6ym/node-pqclean
that referenced
this pull request
Sep 29, 2025
All supported Node.js release lines have increased the stack size on Windows, so it is no longer necessary to use WebAssembly to access certain algorithms on Windows. Refs: nodejs/node#43632
everest-an
added a commit
to edwin-hao-ai/AwarenessClaw
that referenced
this pull request
Apr 8, 2026
…all paths Stack-size changes: - NODE_STACK_SIZE_KB unified to 8192 on all platforms (was 900 on Windows) - The 900 value was based on nodejs/node#43630 which described a pre-v18.6 limitation (1 MiB PE StackReserveSize). Node.js PR #43632 (merged July 2022, backported to v18.6.0/v16.17.0) increased Windows StackReserveSize to 8 MiB, making --stack-size=8192 safe. Verified via PE header inspection of node.exe v22.22.1: StackReserve=0x800000 (8 MiB). - shell-utils.ts comment updated to reference nodejs/node#43632. Gateway patch extraction: - patchGatewayCmdStackSize() extracted from main.ts to openclaw-config.ts as a shared utility (accepts homedir parameter instead of using module global). - main.ts now imports and calls the shared function at all 3 existing sites. Doctor gap fix: - checks-infra.ts: patchGatewayCmdStackSize() now called after every 'openclaw gateway install' (2 code paths) to prevent gateway.cmd from losing the --stack-size injection when the service is reinstalled. Gateway restart hardening: - All 'openclaw gateway restart' call sites now call patchGatewayCmdStackSize() on Windows before restarting, ensuring gateway.cmd always has --stack-size=8192 regardless of who regenerated it. - Affected files: register-channel-config-handlers.ts (4 sites), register-channel-setup-handlers.ts (1 site), register-app-runtime-handlers.ts (1 site), checks-channels.ts (1 site). Prior session changes included in this commit: - channel-login-flow.ts: refactored to use runSpawn instead of cmd.exe shell - shell-utils.ts: filesystem fast-path for getOpenClawPackageDirSync() - register-channel-setup-handlers.ts: killStaleChannelLogins await fix - register-runtime-health-handlers.ts, register-setup-handlers.ts: related test mock updates Impact: All gateway start/restart/install paths on Windows now guarantee --stack-size=8192, eliminating the AJV stack overflow (0xC00000FD) that caused WeChat channel crashes. No behavioral change on macOS/Linux. Verification: Electron tsconfig compilation passes. 562/567 tests pass (5 failures are pre-existing in register-agent-handlers.test.ts due to stale mock data, unrelated to this change).
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.
Increase the virtual stack space available to each thread from 1 MiB to 8 MiB.
Fixes: #43630