-
Notifications
You must be signed in to change notification settings - Fork 0
fix(ci): align npm to packageManager to unblock npm ci #169
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -15,10 +15,15 @@ jobs: | |
| react-version: [18, 19] | ||
| steps: | ||
| - uses: actions/checkout@v7 | ||
| - uses: actions/setup-node@v6 | ||
| - uses: actions/setup-node@v7 | ||
| with: | ||
| node-version: 20 | ||
| cache: npm | ||
| # package.json declares packageManager: npm@11.12.1. The runner ships npm | ||
| # 10.x, whose `npm ci` misreads the npm-11 lockfile (false "react@18.3.1 | ||
| # missing"). Pin npm to the declared version before installing. | ||
| - name: Align npm to packageManager | ||
| run: npm install -g npm@11.12.1 | ||
|
Comment on lines
+25
to
+26
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
On every push to Useful? React with 👍 / 👎. |
||
| - run: npm ci | ||
| - run: npm install --no-save react@${{ matrix.react-version }} react-dom@${{ matrix.react-version }} | ||
| - run: npm run lint | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
actions/setup-node@v7does not identify a released action version; this repository's Dependabot history upgraded setup-node to the available v6 while its other workflows also remain on v6. Consequently, every CI matrix job will fail while resolving the action, before the new npm-alignment step can run, so keep this reference on v6 unless a real v7 release is available.Useful? React with 👍 / 👎.