mirror of
https://github.com/Pasta-Devs/Marinara-Engine.git
synced 2026-12-03 19:00:50 +07:00
[PR #7786] [MERGED] fix(build): give the desktop client build the heap its type-check needs #7927
Labels
No labels
android
bug
bugfix
ci
client
code freeze pause
container
dependencies
docs
documentation
duplicate
enhancement
feature
feature
feature
feature-creep
fixed-in-refactor
fixed-in-staging
good first issue
help wanted
in-pr
in-pr
needs-codeowner-decision
normal-scope
old-codebase
old-codebase
pull-request
qol
question
refactor
regression
revisit later
roadmap
scope-risk
scope-risk
server
server
shared
soup
upstream
windows
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
Pasta-Devs/Marinara-Engine#7927
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/Pasta-Devs/Marinara-Engine/pull/7786
Author: @ylli-selmani
Created: 10/18/2026
Status: ✅ Merged
Merged: 10/18/2026
Merged by: @ylli-selmani
Base:
staging← Head:fix/client-build-heap📝 Commits (5)
de8afe9fix(build): give the desktop client build the heap its type-check needsc02d6b9fix(build): a NODE_OPTIONS heap spelled with underscores also wins09bfa34fix(build): recognize the heap flag only as its own optione347ec0fix(build): read NODE_OPTIONS the way Node does before looking for a heap8724456fix(build): respect a container's memory limit and the heap percentage flag📊 Changes
3 files changed (+120 additions, -4 deletions)
View changed files
📝
packages/client/scripts/build-heap.mjs(+61 -0)📝
packages/client/scripts/build.mjs(+4 -2)📝
scripts/regressions/launcher/termux-client-build.regression.mjs(+55 -2)📄 Description
Linked issue
Closes #7785
Why this change
Native install/buildon the macOS runners runs out of memory in the client build's type-check, on every run of any branch that has merged currentstaging(seen on #7773). A cold type-check of the client now needs about 2.1 GiB of heap. Node's default heap is about 4 GiB on a 16 GiB machine but only about 2 GiB on the 7 GiB macOS runners, andbuild.mjsonly raised the heap for Android builds.@SpicyMarinara, flagging this one since it blocks macOS CI on anything based on current
staging, ahead of the release.What changed
packages/client/scripts/build-heap.mjs: a desktop rule beside the Termux one. A desktop build gets 3072 MiB when Node's own default is lower and half the machine's memory allows it.NODE_OPTIONS(the user's) is left alone.packages/client/scripts/build.mjsuses the Termux rule for low-memory builds and the desktop rule otherwise. It only sets the heap for the build's own children, as before.termux-client-build.regression.mjscovers the desktop rule: a 7 GiB machine gets 3072, a 4 GiB default is kept, never more than half the memory, and aNODE_OPTIONSheap wins.Validation
pnpm checkpasses locallyCONTRIBUTING.mdManual verification notes
tscof the client with--extendedDiagnostics: 2.14 GB on #7773's branch and 2.15 GB on a branch whose macOS build passed, so the macOS runners sit right at the line. The CI crash stops at 2041.9 MB.build.mjswhile reporting a 7 GiB machine with a 2048 MiB default: it logsClient build heap limit: 3072 MiB.and the client builds (tsc, Vite, multiplayer guest).pnpm regression:launcher-updateandtermux-client-build.regression.mjspass. The full regression run (complete-node-regressions) includes the Termux file, so the new cases run in CI.Not tested: an actual macOS runner; this PR's own Platform Artifact Checks will be that test. Every path that builds the client goes through
build.mjs(pnpm build, the launchers' updates, the Windows installer'sinstall.bat), so users on low-memory desktops get the same rule: 3072 MiB only where half their memory allows it and Node's default is lower.Docs and release impact
docs-i18nbranch updated to match, or a[docs-i18n]follow-up issue opened (see CONTRIBUTING.md § Translated documentation)🤖 Generated with Claude Code
Summary by CodeRabbit
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.