Cannot install Truffle via npm install -g truffle command
Expected to install the latest truffle globally using npm
\npm-cli.js" "install" "-g" "truffle"
npm ERR! node v7.10.0
npm ERR! npm v3.10.6
npm ERR! code ELIFECYCLE
npm ERR! [email protected] install: node-gyp rebuild
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] install script 'node-gyp rebuild'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the sha3 package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! node-gyp rebuild
npm ERR! You can get information on how to open an issue for this project with:
npm ERR! npm bugs sha3
npm ERR! Or if that isn't available, you can get their info via:
npm ERR! npm owner ls sha3
npm ERR! There is likely additional logging output above.
npm ERR! Please include the following file with any support request:
npm ERR! C:\Users\dilip.r02\npm-debug.log
npm ERR! code 1
try "npm install [email protected] -g"
for me it worked today
the 3.2.2 version has some issues right now so go for the 3.2.1
Thanks Treste91
Good call @treste91 , thanks!
Does upgrading your node version help? https://github.com/trufflesuite/truffle/issues/413#issuecomment-305923926
Hi there. A new beta has been pushed out that should fix this issue. Details in the blog post here. Can you give it a shot and report back?
ran into the same issue today, the suggestion from Treste91 worked for me
On Window, I used GitBash, first ran npm install --global --production windows-build-tools, then opened gitbash as an Administrator and ran the suggestion from Treste91... and voila, 6 hours since starting install, you should have a nice truffle command line
Please read the blog post for a quick, issue free installation on Windows:
http://truffleframework.com/blog/how-were-making-installation-issues-a-thing-of-the-past
Per the blog post, truffle (beta) has successfully installed for me on Win7 with Python 2.7 using npm:
$ npm install -g truffle@beta
We've released a new version of Truffle making beta officially released to production. Closing this ticket. Thanks all!
I had a similar problem. I ran npm i -g truffle and then when I tried to run truffle init I got an error: zsh: command not found: truffle. What solved it for me is to create a local node_modules with truffle installed in it, and then run that copy.
npm init and make a new npm projectnpm i truffle./node_modules/.bin/truffle init and it should work!
Most helpful comment
try "npm install [email protected] -g"
for me it worked today
the 3.2.2 version has some issues right now so go for the 3.2.1