Skip to content

Require Node 24 in devEngines so it matches the npm >=11 requirement - #4481

Merged
sejas merged 1 commit into
Automattic:trunkfrom
t-hamano:raise-devengines-node-to-24
Aug 12, 2026
Merged

Require Node 24 in devEngines so it matches the npm >=11 requirement#4481
sejas merged 1 commit into
Automattic:trunkfrom
t-hamano:raise-devengines-node-to-24

Conversation

@t-hamano

@t-hamano t-hamano commented Aug 7, 2026

Copy link
Copy Markdown
Contributor

Related issues

  • None — found while setting up a local dev environment.
studio-node

How AI was used in this PR

Claude Code investigated the failing npm install, traced it to the contradiction between the two devEngines constraints, and made the one-line change. I reviewed the reasoning and confirmed the resulting Node/npm resolution locally.

Proposed Changes

The two devEngines constraints contradict each other: runtime allows Node 22, but Node 22 bundles npm 10.9.x, which can never satisfy packageManager: ">=11.0.0". A contributor whose version manager honours the declared runtime floor is blocked from installing at all, with an EBADDEVENGINES error that blames npm rather than Node. Meanwhile, .nvmrc pins 24.15.0.

Testing Instructions

  1. Check out this branch and make sure your version manager picks up the change.
  2. node -v should report 24.x, and npm -v should report 11.x.
  3. npm install should complete without EBADDEVENGINES.

To see the original failure, switch to trunk with a version manager that reads devEngines (or run npm install under Node 22) — the install aborts with the error above.

Pre-merge Checklist

  • Have you checked for TypeScript, React or other console errors?

Co-Authored-By: Claude <noreply@anthropic.com>
@t-hamano
t-hamano marked this pull request as ready for review August 7, 2026 14:40

@sejas sejas left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@t-hamano , thanks for creating this PR. The change looks good to me. We could even specify the version 24.15.0 which lives in .nvmrc.

@fredrikekelund, I would like to know your opinion about increasing the devEngines node runtime version in package.json.

@sejas
sejas merged commit c014a69 into Automattic:trunk Aug 12, 2026
23 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants