由于某些节点 gyp 和节点-sass 相关问题,纱线崩溃

yarn is crashing due to some node gyp and node-sass related issues

我尝试了 github 个问题和 Whosebug 的许多不同答案,但没有解决。

这可能是一个 OS 相关的问题吗?我目前试过 windows 和 ubuntu。 ps: 该项目在 MacOS 上运行没有任何错误 节点 - 16.13.0 项目 v6.0.0 中的节点 sass, os - ubuntu 20 磅 python,已安装构建要素。

错误日志:

   make: *** [deasync.target.mk:113: Release/obj.target/deasync/src/deasync.o] Error 1
gyp ERR! build error 
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack     at ChildProcess.onExit (/home/sandrin/.nvm/versions/node/v16.13.0/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:194:23)
gyp ERR! stack     at ChildProcess.emit (node:events:390:28)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (node:internal/child_process:290:12)
gyp ERR! System Linux 5.13.0-40-generic
gyp ERR! command "/home/sandrin/.nvm/versions/node/v16.13.0/bin/node" "/home/sandrin/.nvm/versions/node/v16.13.0/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /home/sandrin/.cache/yarn/v6/.tmp/c7cdac7c2a9ce67dc3216b3d4e04aab2.9416114cb72b213593bf054fa28cd205f526e5f3.prepare/node_modules/deasync
gyp ERR! node -v v16.13.0
gyp ERR! node-gyp -v v8.2.0
gyp ERR! not ok 
make: Leaving directory '/home/sandrin/.cache/yarn/v6/.tmp/c7cdac7c2a9ce67dc3216b3d4e04aab2.9416114cb72b213593bf054fa28cd205f526e5f3.prepare/node_modules/deasync/build'



[4/4] Building fresh packages...
[1/1] ⠂ node-sass

进程卡在节点-sass

您应该从 node-sass to sass(又名 Dart Sass)切换。

node-sass(它使用了您显然在编译时遇到问题的本机模块)已弃用; node-sass:

的 npm 页面引述

Warning: LibSass and Node Sass are deprecated. While they will continue to receive maintenance releases indefinitely, there are no plans to add additional features or compatibility with any new CSS or Sass features. Projects that still use it should move onto Dart Sass.