[BUG] npm install npm error Cannot read properties of null (reading 'edgesOut')
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 10.1k
- Forks
- 4.7k
- Avg merge
- 2d 2h
- Merged PRs (30d)
- 19
Description
Is there an existing issue for this?
- I have searched the existing issues
This issue exists in the latest npm version
- I am using the latest npm
This is not just a request to bump a dependency for a CVE
- This is not solely a request to bump a dependency for a CVE
Current Behavior
3835 verbose stack TypeError: Cannot read properties of null (reading 'edgesOut')
3835 verbose stack at #loadPeerSet (/usr/lib/node_modules/npm/node_modules/@npmcli/arborist/lib/arborist/build-ideal-tree.js:1289:38)
3835 verbose stack at async #loadPeerSet (/usr/lib/node_modules/npm/node_modules/@npmcli/arborist/lib/arborist/build-ideal-tree.js:1297:11)
3835 verbose stack at async #buildDepStep (/usr/lib/node_modules/npm/node_modules/@npmcli/arborist/lib/arborist/build-ideal-tree.js:904:11)
3835 verbose stack at async Arborist.buildIdealTree (/usr/lib/node_modules/npm/node_modules/@npmcli/arborist/lib/arborist/build-ideal-tree.js:181:7)
3835 verbose stack at async Promise.all (index 1)
3835 verbose stack at async Arborist.reify (/usr/lib/node_modules/npm/node_modules/@npmcli/arborist/lib/arborist/reify.js:131:5)
3835 verbose stack at async Install.exec (/usr/lib/node_modules/npm/lib/commands/install.js:150:5)
3835 verbose stack at async Npm.exec (/usr/lib/node_modules/npm/lib/npm.js:207:9)
3835 verbose stack at async module.exports (/usr/lib/node_modules/npm/lib/cli/entry.js:74:5)
{
"name": "nuxt-app",
"private": true,
"scripts": {
"dev": "nuxt dev",
"build": "nuxt build",
"analyze": "nuxt analyze --serve",
"generate": "nuxt generate",
"preview": "nuxt preview",
"postinstall": "nuxt prepare",
"generate-pwa-assets": "pwa-assets-generator",
"typecheck": "nuxt typecheck",
"lint": "eslint .",
"lint:fix": "eslint . --fix",
"prestart": "test -f .output/server/index.mjs || npm run build",
"start": "node .output/server/index.mjs",
"start:prod": "NODE_ENV=production node .output/server/index.mjs"
},
"engines": {
"node": ">=20.0.0"
},
"devDependencies": {
"@nuxt/eslint-config": "^1.15.2",
"@nuxtjs/device": "^3.2.4",
"@nuxtjs/google-fonts": "^3.2.0",
"@nuxtjs/i18n": "^9.5.3",
"@tailwindcss/aspect-ratio": "^0.4.2",
"@tailwindcss/forms": "^0.5.10",
"@types/lodash-es": "4.17.12",
"@vite-pwa/assets-generator": "^1.0.0",
"@vite-pwa/nuxt": "^1.0.0",
"autoprefixer": "^10.4.21",
"eslint": "^9.39.3",
"nuxt": "3.21.1",
"nuxt-gtag": "^3.0.2",
"nuxt-purgecss": "^2.0.0",
"postcss": "^8.5.1",
"tailwindcss": "^3.4.10"
},
"dependencies": {
"@headlessui/vue": "^1.7.23",
"@heroicons/vue": "^2.2.0",
"@microsoft/signalr": "^8.0.7",
"@nuxt/image": "^1.10.0",
"@pinia/nuxt": "^0.11.0",
"@tawk.to/tawk-messenger-vue-3": "^1.0.3",
"@vuepic/vue-datepicker": "^11.0.2",
"@vueuse/components": "^13.1.0",
"@vueuse/core": "^13.1.0",
"color": "^5.0.0",
"crypto-js": "^4.2.0",
"eventemitter3": "^5.0.1",
"gsap": "^3.12.7",
"lodash-es": "^4.17.21",
"lottie-web": "5.12.2",
"mersenne-twister": "^1.1.0",
"nuxt-toast": "^1.1.4",
"pinia": "^3.0.2",
"qrcode-vue3": "^1.7.1",
"sass": "^1.86.3",
"swiper": "^11.2.6",
"vue-chartjs": "^5.3.3",
"vue3-marquee": "^4.2.2",
"jsqr": "^1.4.0"
}
}
node v22.21.0
npm v10.8.2
Expected Behavior
No response
Steps To Reproduce
- In this environment...
- With this config...
- Run '...'
- See error...
Environment
- npm:
- Node.js:
- OS Name:
- System Model Name:
- npm config:
; copy and paste output from `npm config ls` here
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start at node_modules/@npmcli/arborist/lib/arborist/build-ideal-tree.js:1289 and trace #loadPeerSet through buildIdealTree, using the supplied package.json and Node/npm versions to reproduce npm install. Done means the reported null edgesOut failure no longer occurs and the install completes; the issue does not name a regression test.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, node.js
- Domain
- cli, tooling
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Active
- Clarity
- Needs clarification
- Newbie friendliness
- 42/100