如何解决如何在 windows 上安装 truffle5.0.2?
我准备安装 truffle5.0.2 来测试智能合约,但效果不佳。 经过一些研究,我可以找到一些解决方案,但不幸的是,它们不起作用。 这是错误日志。
0 info it worked if it ends with ok
1 verbose cli [ 'C:\\Program Files\\nodejs\\node.exe',1 verbose cli 'C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js',1 verbose cli 'run',1 verbose cli 'rebuild' ]
2 info using npm@6.9.0
3 info using node@v10.16.0
4 verbose run-script [ 'prerebuild','rebuild','postrebuild' ]
5 info lifecycle keccak@1.4.0~prerebuild: keccak@1.4.0
6 info lifecycle keccak@1.4.0~rebuild: keccak@1.4.0
7 verbose lifecycle keccak@1.4.0~rebuild: unsafe-perm in lifecycle true
8 verbose lifecycle keccak@1.4.0~rebuild: PATH: C:\Program Files\nodejs\node_modules\npm\node_modules\npm-lifecycle\node-gyp-bin;C:\Users\Lucas\AppData\Roaming\npm\node_modules\truffle\node_modules\keccak\node_modules\.bin;C:\Users\Lucas\AppData\Roaming\npm\node_modules\truffle\node_modules\.bin;C:\Users\Lucas\AppData\Roaming\npm\node_modules\.bin;C:\Program Files\nodejs\node_modules\npm\node_modules\npm-lifecycle\node-gyp-bin;C:\Users\Lucas\AppData\Roaming\npm\node_modules\truffle\node_modules\keccak\node_modules\.bin;C:\Users\Lucas\AppData\Roaming\npm\node_modules\truffle\node_modules\.bin;C:\Users\Lucas\AppData\Roaming\npm\node_modules\.bin;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Windows\System32\OpenSSH\;C:\Program Files (x86)\NVIDIA Corporation\PhysX\Common;C:\Program Files\nodejs\;C:\Program Files (x86)\Yarn\bin\;C:\Program Files\Git\cmd;C:\ProgramData\chocolatey\bin;C:\tools\php80;C:\ProgramData\ComposerSetup\bin;C:\Program Files\PuTTY\;C:\tools\php74;C:\Program Files\WireGuard\;C:\Users\Lucas\AppData\Local\Microsoft\WindowsApps;C:\Users\Lucas\AppData\Local\Programs\Microsoft VS Code\bin;C:\Users\Lucas\AppData\Roaming\npm;C:\Users\Lucas\AppData\Local\Yarn\bin;C:\Users\Lucas\AppData\Roaming\Composer\vendor\bin
9 verbose lifecycle keccak@1.4.0~rebuild: CWD: C:\Users\Lucas\AppData\Roaming\npm\node_modules\truffle\node_modules\keccak
10 silly lifecycle keccak@1.4.0~rebuild: Args: [ '/d /s /c','node-gyp rebuild' ]
11 silly lifecycle keccak@1.4.0~rebuild: Returned: code: 1 signal: null
12 info lifecycle keccak@1.4.0~rebuild: Failed to exec rebuild script
13 verbose stack Error: keccak@1.4.0 rebuild: `node-gyp rebuild`
13 verbose stack Exit status 1
13 verbose stack at EventEmitter.<anonymous> (C:\Program Files\nodejs\node_modules\npm\node_modules\npm-lifecycle\index.js:301:16)
13 verbose stack at EventEmitter.emit (events.js:198:13)
13 verbose stack at ChildProcess.<anonymous> (C:\Program Files\nodejs\node_modules\npm\node_modules\npm-lifecycle\lib\spawn.js:55:14)
13 verbose stack at ChildProcess.emit (events.js:198:13)
13 verbose stack at maybeClose (internal/child_process.js:982:16)
13 verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js:259:5)
14 verbose pkgid keccak@1.4.0
15 verbose cwd C:\Users\Lucas\AppData\Roaming\npm\node_modules\truffle\node_modules\keccak
16 verbose Windows_NT 10.0.18363
17 verbose argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "run" "rebuild"
18 verbose node v10.16.0
19 verbose npm v6.9.0
20 error code ELIFECYCLE
21 error errno 1
22 error keccak@1.4.0 rebuild: `node-gyp rebuild`
22 error Exit status 1
23 error Failed at the keccak@1.4.0 rebuild script.
23 error This is probably not a problem with npm. There is likely additional logging output above.
24 verbose exit [ 1,true ]
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。