Hyperledger Fabric - npm install 依赖项错误 "grpc@1.17.0 install: `node-pre-gyp install --fallback-to-bui



Hyperledger Fabric 商业票据示例 (https://hyperledger-fabric.readthedocs.io/en/release-1.4/tutorial/commercial_paper.html( 在尝试使用 npm install 安装 Magneto 应用程序依赖项时给了我此错误。

日志:

1359 verbose stack Error: grpc@1.17.0 install: `node-pre-gyp install --fallback-to-build --library=static_library`
1359 verbose stack Exit status 1
1359 verbose stack     at EventEmitter.<anonymous> (/home/hyperfabric/.nvm/versions/node/v12.4.0/lib/node_modules/npm/node_modules/npm-lifecycle/index.js:301:16)
1359 verbose stack     at EventEmitter.emit (events.js:200:13)
1359 verbose stack     at ChildProcess.<anonymous> (/home/hyperfabric/.nvm/versions/node/v12.4.0/lib/node_modules/npm/node_modules/npm-lifecycle/lib/spawn.js:55:14)
1359 verbose stack     at ChildProcess.emit (events.js:200:13)
1359 verbose stack     at maybeClose (internal/child_process.js:1021:16)
1359 verbose stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:283:5)
1360 verbose pkgid grpc@1.17.0
1361 verbose cwd /home/hyperfabric/go/src/testFabric/fabric-samples/commercial-paper/organization/magnetocorp/application
1362 verbose Linux 4.15.0-51-generic
1363 verbose argv "/home/hyperfabric/.nvm/versions/node/v12.4.0/bin/node" "/home/hyperfabric/.nvm/versions/node/v12.4.0/bin/npm" "install"
1364 verbose node v12.4.0
1365 verbose npm  v6.9.0
1366 error code ELIFECYCLE
1367 error errno 1
1368 error grpc@1.17.0 install: `node-pre-gyp install --fallback-to-build --library=static_library`
1368 error Exit status 1
1369 error Failed at the grpc@1.17.0 install script.
1369 error This is probably not a problem with npm. There is likely additional logging output above.
1370 verbose exit [ 1, true ]

您正在使用不受支持的 Node.js 版本来构建项目,Fabric 目前支持 8.9.x 版本的 Node 构建,我建议您查看此处的先决条件,并确保您已满足所有要求:

https://hyperledger-fabric.readthedocs.io/en/latest/prereqs.html

最新更新