Skip to content

fix: remove npm update step causing MODULE_NOT_FOUND in CI - #30

Merged
maplezzk merged 1 commit into
mainfrom
fix/ci-npm-corruption
Apr 28, 2026
Merged

maplezzk merged 1 commit into
mainfrom
fix/ci-npm-corruption

Conversation

@maplezzk

Copy link
Copy Markdown
Owner

问题

release.yml 中 npm install -g npm@latest 在 GitHub Actions Node 22.22.2 runner 上报错:

npm error code MODULE_NOT_FOUND
npm error Cannot find module 'promise-retry'

这是 Node 22 预装 npm 损坏的已知问题。

修复

移除不必要的 "Update npm to latest" 和 "Check npm version" 步骤。setup-node@v4 本身已提供可用的 npm,无需手动升级。

The Node 22.22.2 runner has a corrupted npm installation missing the
promise-retry module. Removing the unnecessary 'npm install -g npm@latest'
step since setup-node@v4 already provides a working npm.
@maplezzk
maplezzk merged commit 28bcfbd into main Apr 28, 2026
1 check passed
@maplezzk
maplezzk deleted the fix/ci-npm-corruption branch April 28, 2026 14:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant