What is the problem?
一份给新手的 npm install 报错排查清单,覆盖目录、Node/npm 版本、lockfile、网络、权限、私有包、低风险验证和交付记录。
Quick solution
Treat this as a Codex checklist issue. First confirm the environment, inputs, permissions, logs, and delivery boundary. Then use the linked deep guide for the full checklist before changing production code or promising a result.
Read the deep guideDetailed steps
- 当前终端是否在项目根目录。
- 当前目录是否有 package.json。
- 是否有 package-lock.json。
- 是否有 pnpm-lock.yaml 或 yarn.lock。
- 是否有 README、`.nvmrc`、`.npmrc` 或 engines 字段。
- `node -v` 是否可用。
Commands or code
项目目录:
运行命令:
Node/npm 版本:
lockfile 类型:
错误类型:
已尝试动作:
低风险下一步:
需要客户确认:Risk notes
Confirm the real project environment, account permissions, platform rules, and output quality before delivery. Do not ship AI-generated changes without human review, and do not claim indexing, income, deployment success, or ranking improvements without measured evidence.