Skip to content

Commit a085fd5

Browse files
seanghayclaude
andcommitted
ci: upgrade to npm 11 before install
npm 10 (bundled with Node 20 and 22) crashes while resolving tsdown's optional `@vitejs/devtools: *` peer dependency, failing `npm install` with "Cannot read properties of null (reading 'edgesOut')". npm 11 resolves it correctly, so upgrade npm before installing in both the test and publish jobs. This is a pre-existing npm bug independent of the skia migration — it reproduces on the previous package.json too — surfaced by a recent tsdown publish. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
1 parent 778bf68 commit a085fd5

1 file changed

Lines changed: 9 additions & 1 deletion

File tree

.github/workflows/tests.yaml

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,11 @@ jobs:
3232
with:
3333
node-version: ${{ matrix.node }}
3434

35+
# npm 10 (bundled with Node 20/22) crashes resolving tsdown's optional
36+
# `@vitejs/devtools: *` peer with "Cannot read properties of null
37+
# (reading 'edgesOut')". npm 11 handles it, so upgrade before installing.
38+
- run: npm install -g npm@11
39+
3540
- run: npm install
3641
- run: npm test
3742
- run: npm run build
@@ -49,7 +54,10 @@ jobs:
4954
with:
5055
node-version: 22
5156
registry-url: https://registry.npmjs.org
52-
57+
58+
# See the note in run-tests: npm 10 crashes on tsdown's optional peer.
59+
- run: npm install -g npm@11
60+
5361
- run: npm install
5462
- run: npm publish --provenance --access public
5563
env:

0 commit comments

Comments
 (0)