“npm install”卡住并在“reify:date-fns”安装行出错

问题描述 投票:0回答:1

所以当我运行“npm install”几分钟时,我的项目就卡在了这一行,之后它抛出了一些巨大的错误,我不能只是将它粘贴到这里,因为它太大了。

但是错误的开始是:

npm WARN deprecated [email protected]: You can find the new Popper v2 at @popperjs/core, this package is dedicated to the legacy v1
npm ERR! code 1
npm ERR! path /home/joao/Desktop/camaleao/camaleao-web-frontend/node_modules/node-sass
npm ERR! command failed
npm ERR! command sh -c node scripts/build.js
npm ERR! Building: /usr/local/bin/node /home/joao/Desktop/camaleao/camaleao-web-frontend/node_modules/node-gyp/bin/node-gyp.js rebuild --verbose --libsass_ext= --libsass_cflags= --libsass_ldflags= --libsass_library=
npm ERR! make: Entrando no diretório '/home/joao/Desktop/camaleao/camaleao-web-frontend/node_modules/node-sass/build'
npm ERR!   g++ '-DNODE_GYP_MODULE_NAME=libsass' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIB

错误结束:

npm ERR! gyp ERR! stack Error: `make` failed with exit code: 2
npm ERR! gyp ERR! stack     at ChildProcess.onExit (/home/joao/Desktop/camaleao/camaleao-web-frontend/node_modules/node-gyp/lib/build.js:262:23)
npm ERR! gyp ERR! stack     at ChildProcess.emit (node:events:390:28)
npm ERR! gyp ERR! stack     at Process.ChildProcess._handle.onexit (node:internal/child_process:290:12)
npm ERR! gyp ERR! System Linux 5.11.0-44-generic
npm ERR! gyp ERR! command "/usr/local/bin/node" "/home/joao/Desktop/camaleao/camaleao-web-frontend/node_modules/node-gyp/bin/node-gyp.js" "rebuild" "--verbose" "--libsass_ext=" "--libsass_cflags=" "--libsass_ldflags=" "--libsass_library="
npm ERR! gyp ERR! cwd /home/joao/Desktop/camaleao/camaleao-web-frontend/node_modules/node-sass
npm ERR! gyp ERR! node -v v16.13.1
npm ERR! gyp ERR! node-gyp -v v3.8.0
npm ERR! gyp ERR! not ok 
npm ERR! Build failed with error code: 1

已经删除了package-lock.json和node-modules。

❯节点-v
v16.13.1

❯ npm -v
8.3.0

node.js npm
1个回答
0
投票

就我而言,我尝试升级 npm。但我也被困在那里。

完全删除节点并重新安装它解决了我的问题。

© www.soinside.com 2019 - 2024. All rights reserved.