Repository navigation
fix(build): align engines.node with SUPPORTED_NODE_RANGE (#7446) - #7490
diegosouzapw merged 3 commits into
Conversation
There was a problem hiding this comment.
Code Review
This pull request updates the supported Node.js engine range in package.json and README.md from >=22.0.0 <23 || >=24.0.0 <27 to >=22.22.2 <23 || >=24.0.0 <27 to prevent installation on unsupported Node 22 versions (specifically the 22.0.0–22.22.1 gap). It also adds a regression test in tests/unit/node-runtime-support.test.ts to ensure that the engines.node property in package.json remains synchronized with the SUPPORTED_NODE_RANGE constant. There are no review comments to address, and I have no additional feedback to provide.
Important
The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.
|
Thanks for this — confirmed the drift is real on release/v3.8.49 ( We have a second PR, #7510, opened a few hours after this one, fixing the exact same package.json/package-lock.json/README.md lines — byte-identical diff on those three files. The only difference is the regression test: yours reads package.json via We'll also fold in two more stale |
…tale README refs (cheaper-inference#7446) Merges origin/release/v3.8.49 (134 commits) to resolve drift and keep this fix current. One real conflict in README.md's Features & Architecture table (unrelated spacer-image column-width formatting release added after this branch forked) — resolved in favor of the release-tip formatting, which matches the rest of the file's doc-link tables. Also fixes two remaining stale `>=22.0.0`/`≥22.0.0` Node references left unaddressed by the original fix (troubleshooting table + footer badge), so every Node version reference in README.md agrees with SUPPORTED_NODE_RANGE (`>=22.22.2 <23 || >=24.0.0 <27`). Co-authored-by: diegosouzapw <8016841+diegosouzapw@users.noreply.github.com>
Co-authored-by: diegosouzapw <8016841+diegosouzapw@users.noreply.github.com>
2887937
into
cheaper-inference:release/v3.8.49
|
Thanks @alltomatos! Merged into release/v3.8.49 — validated in the combined merge-train, all gates green. Great catches (Next16 async params, credential-tuple dedupe). |
…erence#7446) (cheaper-inference#7490) * fix(build): align engines.node with SUPPORTED_NODE_RANGE (cheaper-inference#7446) * docs(changelog): add 7490 engines-node alignment fragment Co-authored-by: diegosouzapw <8016841+diegosouzapw@users.noreply.github.com> --------- Co-authored-by: diegosouzapw <8016841+diegosouzapw@users.noreply.github.com>
…erence#7446) (cheaper-inference#7490) * fix(build): align engines.node with SUPPORTED_NODE_RANGE (cheaper-inference#7446) * docs(changelog): add 7490 engines-node alignment fragment Co-authored-by: diegosouzapw <8016841+diegosouzapw@users.noreply.github.com> --------- Co-authored-by: diegosouzapw <8016841+diegosouzapw@users.noreply.github.com>
Problem
engines.nodeinpackage.jsonand the runtime support gate published different Node 22 floors, so npm would happily install OmniRoute on a Node version the runtime then rejects.package.json→engines.node>=22.0.0 <23 || >=24.0.0 <27src/shared/utils/nodeRuntimeSupport.ts→SUPPORTED_NODE_RANGE>=22.22.2 <23 || >=24.0.0 <27README.mdpublished a third phrasing matching the permissiveenginesvalue.Root cause
enginesis the only signal npm consults at install time, butSECURE_NODE_LINES(nodeRuntimeSupport.ts) sets the 22 line at22.22.2(a deliberate security floor), andSUPPORTED_NODE_RANGEis what the runtime gate enforces. For the gap Node 22.0.0 – 22.22.1,npm install -g omniroute(andnpm ci) pass the engine check, then the server refuses to start — the failure surfaces at the least helpful moment, with no hint at install time.Fix
Make
SUPPORTED_NODE_RANGEthe single source of truth and align the install-time gate to it (the security floor is the one worth honoring, not the looser one):package.json→engines.node→>=22.22.2 <23 || >=24.0.0 <27(and the mirrored root-packageenginesinpackage-lock.json).README.mdTech Stack runtime line →>=22.22.2 <23 || >=24.0.0 <27.docs/guides/TERMUX_GUIDE.mdalready published>=22.22.2 …and asserted it "matchesenginesinpackage.json/SUPPORTED_NODE_RANGE" — that claim is now actually true (no change needed).A regression test asserts
package.json'sengines.nodeequalsSUPPORTED_NODE_RANGE, so the install-time gate and the runtime gate can never drift again. Its natural home —tests/unit/node-runtime-support.test.ts— already imports the constant.Verification
Diff summary
package.json—engines.nodefloor22.0.0→22.22.2(Node 22 line).package-lock.json— mirror the root-packageenginesvalue.README.md— Tech Stack runtime range aligned; the repo'slint-staged/Prettier hook also normalized whitespace in two nearby Markdown tables it touched (cosmetic, no content change).tests/unit/node-runtime-support.test.ts— add anti-drift regression test.Closes #7446.
Thanks @diegosouzapw for the precise write-up and pinpointing the exact
22.0.0–22.22.1gap — it made this a one-line source fix plus a guard.