Repository navigation
ci: pin Node.js to 24.22.1 in .nvmrc - #81
Merged
Merged
Conversation
.nvmrc was lts/*, which now resolves to Node 26 (LTS since 2026-10-28).
The Check workflows job uses .nvmrc, and on Node 26 its install fails: the
allow-scripts plugin runs @lavamoat/allow-scripts, which loads yargs 17.7.2
(require('yargs/yargs') is an extension-less file in an ESM package) and
throws 'require is not defined in ES module scope'. Pin the supported
Node 24 release.
pnarayanaswamy
approved these changes
Nov 2, 2026
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.
Pins
.nvmrcto Node.jsv24.22.1instead oflts/*.Why
lts/*now resolves to Node 26 (26.13.0 became LTS on 2026-10-28). The Check workflows job does not set a Node version, so it follows.nvmrc, and on Node 26 itsyarn --immutablestep fails (3 retries), which also fails All jobs pass:The allow-scripts install plugin runs
@lavamoat/allow-scripts(3.4.2), which doesrequire('yargs/yargs'). In yargs 17.7.2 (locked) that is an extension-less file in a"type": "module"package, which Node 26 no longer loads withrequire.main@ e4ce5ed (Oct 29)main@ cc6a9cf, 0.13.0 release (Nov 2)Same change as MetaMask/device-mcp#53. Reproduced there:
node node_modules/@lavamoat/allow-scripts/src/cli.js --helpworks on 24.22.1 and throws the same error on 26.13.0.The build, lint and test jobs set their own matrix (20.x / 22.x / 24.x) and are not affected.
enginesstays^20 || ^22 || >=24.Follow-up (not in this PR)
Node 26 support for the install tooling:
yargs17.7.3 pointsyargs/yargsto a.cjsfile and loads on Node 26 (checked locally), soyarn up -R yargs(or@lavamoat/allow-scripts5.x) would let.nvmrcmove to Node 26 later.