pnp / pnp/sp-dev-fx-controls-react

@microsoft/mgt-spfx 3.1.3 unsupported Engine on Node 22

Open
#2,035 4 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
TypeScript
Stars
433
Forks
418
Avg merge
5d 6m
Merged PRs (30d)
19

Description

On 3.22 there is a package @microsoft/mgt-spfx 3.1.3., which seems to be outdated and doesn't support Node 22, which is an issue on SPFX 1.21.1, because it's works only there:

npm warn EBADENGINE Unsupported engine {
npm warn EBADENGINE package: '@microsoft/mgt-spfx@3.1.3',
npm warn EBADENGINE required: { node: '>=16.13.0 <17.0.0 || >=18.17.1 <19.0.0' },
npm warn EBADENGINE current: { node: 'v22.15.1', npm: '10.9.2' }
npm warn EBADENGINE }

Not sure if it's the replacement, but consider replacing it with @microsoft/mgt-spfx-utils taken from Upgrade to the latest version of Microsoft Graph Toolkit

Category

[ ] Enhancement

[x ] Bug

[ ] Question

Version

3.22.0

Expected / Desired Behavior / Question

all pakages works in Node 22

Observed Behavior

@microsoft/mgt-spfx, seems to be used for Graph API connections, doesn't work in Node 22

Steps to Reproduce

npm install && npm dedupe

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by running npm install && npm dedupe with Node 22 and inspect the resolved @microsoft/mgt-spfx@3.1.3 dependency. Review the linked Microsoft Graph Toolkit upgrade guidance and determine whether updating or replacing that package is appropriate; done means the installation no longer reports an unsupported Node engine.

Written by the indexing model from the issue text.

Assessment

Tech stack
node.js, typescript
Domain
build-system
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
32/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.