Cannot add accounts-password

0
down vote
favorite
I am trying to add accounts-password package to my project, but I get this error instead, I have no clue what causes it or how to fix it. I tried to run

meteor npm install node-gyp rebuild as mentioned in the error but it does not help…

…seed>meteor add accounts-password
=> Errors while adding packages:

While loading package npm-bcrypt@0.8.7:
error: Command failed:
C:\Users…\AppData\Local.meteor\packages\meteor-tool\1.4.0-1\mt-os.windows.x86_
32\dev_bundle\bin\npm.cmd
rebuild --no-bin-links --update-binary
gyp ERR! build error
gyp ERR! stack Error:
C:\Windows\Microsoft.NET\Framework\v4.0.30319\msbuild.exe failed with exit
code: 1
gyp ERR! stack at ChildProcess.onExit
(C:\Users…\AppData\Local.meteor\packages\meteor-tool\1.4.0-1\mt-os.windows.x86
_32\dev_bundle\lib\node_modules\node-gyp\lib\build.js:276:23)
gyp ERR! stack at emitTwo (events.js:87:13)
gyp ERR! stack at ChildProcess.emit (events.js:172:7)
gyp ERR! stack at Process.ChildProcess._handle.onexit
(internal/child_process.js:200:12)
gyp ERR! System Windows_NT 6.1.7601
gyp ERR! command
"C:\Users\…\AppData\Local\.meteor\packages\meteor-tool\1.4.0-1\mt-os.wi
ndows.x86_32\dev_bundle\bin\node.exe"
“C:\Users\…\AppData\Local\.meteor\packages\meteor-tool\1.4.0-1\mt-os.wi
ndows.x86_32\dev_bundle\lib\node_modules\node-gyp\bin\node-gyp.js”
"rebuild"
gyp ERR! cwd
C:\Users…\AppData\Local.meteor\packages\npm-bcrypt\0.8.7\npm\node_modules.tem
p-pilafw\node_modules\bcrypt
gyp ERR! node -v v4.4.7
gyp ERR! node-gyp -v v3.4.0
gyp ERR! not ok

npm ERR! Windows_NT 6.1.7601
npm ERR! argv
"C:\Users\…\AppData\Local\.meteor\packages\meteor-tool\1.4.0-1\mt-os.wi
ndows.x86_32\dev_bundle\bin\node.exe"
“C:\Users\…\AppData\Local\.meteor\packages\meteor-tool\1.4.0-1\mt-os.wi
ndows.x86_32\dev_bundle\lib\node_modules\npm\bin\npm-cli.js”
“rebuild” “–no-bin-links” "–update-binary"
npm ERR! node v4.4.7
npm ERR! npm v3.10.5
npm ERR! code ELIFECYCLE
npm ERR! bcrypt@0.8.7 install: node-gyp rebuild
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the bcrypt@0.8.7 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 bcrypt 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 bcrypt
npm ERR! Or if that isn’t available, you can get their info via:
npm ERR! npm owner ls bcrypt
npm ERR! There is likely additional logging output above.

npm ERR! Please include the following file with any support request:
npm ERR!
C:\Users…\AppData\Local.meteor\packages\npm-bcrypt\0.8.7\npm\node_modules.tem
p-pilafw\npm-debug.log
gyp ERR! build error
gyp ERR! stack Error:
C:\Windows\Microsoft.NET\Framework\v4.0.30319\msbuild.exe failed with exit
code: 1
gyp ERR! stack at ChildProcess.onExit
(C:\Users…\AppData\Local.meteor\packages\meteor-tool\1.4.0-1\mt-os.windows.x86
_32\dev_bundle\lib\node_modules\node-gyp\lib\build.js:276:23)
gyp ERR! stack at emitTwo (events.js:87:13)
gyp ERR! stack at ChildProcess.emit (events.js:172:7)
gyp ERR! stack at Process.ChildProcess._handle.onexit
(internal/child_process.js:200:12)
gyp ERR! System Windows_NT 6.1.7601
gyp ERR! command
"C:\Users\…\AppData\Local\.meteor\packages\meteor-tool\1.4.0-1\mt-os.wi
ndows.x86_32\dev_bundle\bin\node.exe"
“C:\Users\…\AppData\Local\.meteor\packages\meteor-tool\1.4.0-1\mt-os.wi
ndows.x86_32\dev_bundle\lib\node_modules\node-gyp\bin\node-gyp.js”
"rebuild"
gyp ERR! cwd
C:\Users…\AppData\Local.meteor\packages\npm-bcrypt\0.8.7\npm\node_modules.tem
p-pilafw\node_modules\bcrypt
gyp ERR! node -v v4.4.7
gyp ERR! node-gyp -v v3.4.0
gyp ERR! not ok

npm ERR! Windows_NT 6.1.7601
npm ERR! argv
"C:\Users\…\AppData\Local\.meteor\packages\meteor-tool\1.4.0-1\mt-os.wi
ndows.x86_32\dev_bundle\bin\node.exe"
“C:\Users\…\AppData\Local\.meteor\packages\meteor-tool\1.4.0-1\mt-os.wi
ndows.x86_32\dev_bundle\lib\node_modules\npm\bin\npm-cli.js”
“rebuild” “–no-bin-links” "–update-binary"
npm ERR! node v4.4.7
npm ERR! npm v3.10.5
npm ERR! code ELIFECYCLE
npm ERR! bcrypt@0.8.7 install: node-gyp rebuild
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the bcrypt@0.8.7 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 bcrypt 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 bcrypt
npm ERR! Or if that isn’t available, you can get their info via:
npm ERR! npm owner ls bcrypt
npm ERR! There is likely additional logging output above.

npm ERR! Please include the following file with any support request:
npm ERR!
C:\Users…\AppData\Local.meteor\packages\npm-bcrypt\0.8.7\npm\node_modules.tem
p-pilafw\npm-debug.log
Im am using Windows7-x64. meteor 1.4.0.1 and the inspina meteor theme.

I reinstalled meteor, I tried to create a new virgin project and add accounts-password to it, but I get the same issue…

1 Like

meteor npm install --global --production windows-build-tools in PowerShell solved the problem

I have the same problem.
I am new. How exactly do I do what you did to solve your problem? Thanks.

I posted a couple of days ago:

Take a look here: stackoverflow

For newbies like me out there: go to start type in the search bar: Windows PowerShell, right-click on it and open as administrator. The PowerShell opens. Type in ‘meteor npm install --global --production windows-build-tools’ and then wait, wait, and wait some longer. After everything is installed, there was no confirmation. But somehow that fixed the issue, and now I can add the accounts-password package.

Thanks for your help. It worked for me too.

I think I can also use cmd.exe with administrator rights. I don’t think I have to first navigate to any particular folder; I just type ‘meteor npm install --global --production windows-build-tools’ and press enter and wait maybe an hour or more. Like you say: there is no confirmation.

Thanks as well - this worked for me in Powershell but NOT with cmd.exe (admin rights)

I did the power shell command as shown, and it succeeded, but I have no change with the add accounts-password command. I still get the bcrypt 0.8.7 error. I am on Windows 7 x64. Any ideas, or things I can check? What is this error actually telling me?
Does the meteor command need to be executed in a powershell?

I’m having the exact same error

For everyone having “the same” error, please post your first 10 lines or so. I have been investigating and it appears a configuration issue is the culprit. In my case, I have VS 2015 installed, and apparently have many copies of the “msbuild” tools floating around. Note the bolded line is different from the OP.

D:\K4\meteor\tutorial>meteor add accounts-password
=> Errors while adding packages:

While loading package npm-bcrypt@0.8.7:
error: Command failed:
C:\Users\jgg\AppData\Local.meteor\packages\meteor-tool\1.4.0\mt-os.windows.x86_
32\dev_bundle\bin\npm.cmd
rebuild --no-bin-links --update-binary
gyp ERR! build error
gyp ERR! stack Error: C:\Program Files(x86)\MSBuild\14.0\bin\msbuild.exe failed with exit code: 1
gyp ERR! stack at ChildProcess.onExit
(C:\Users\jgg\AppData\Local.meteor\packages\meteor-tool\1.4.0\mt-os.windows.x86
_32\dev_bundle\lib\node_modules\npm\node_modules\node-gyp\lib\build.js:276:23)
gyp ERR! stack at emitTwo (events.js:87:13)
gyp ERR! stack at ChildProcess.emit (events.js:172:7)
gyp ERR! stack at Process.ChildProcess._handle.onexit
(internal/child_process.js:200:12)
gyp ERR! System Windows_NT 6.1.7601

The new Meteor version wants to compile things with node-gyp, which requires c++ build tools. I used VS 2015 since the other methods were not working for me. The trick with VS 2015 is that the C++ tools are not installed by default (don’t ask me why), you need to modify the installation to include the C++ tools.

If you go to modify programs and settings, and click on VS 2015 it should bring up the installer thingy. Click “modify” at the bottom and that will take you to a bunch of checkboxes. Find the C++ category, and pick the important looking one, it should be at the top of the list (you don’t need the MFC or XP compatibility thing). After that restart your command prompt and it should work (at least it did for me).

Hope that helps!

Thanks for responding, but doesn’t the original answer of

“meteor npm install --global --production windows-build-tools” in PowerShell solved the problem

do the same thing? That is, I think I have the build tools, from multiple sources, but I am still getting the exact same error, which doesn’t say the build tools are missing. The msbuild.exe is sitting right where the error says it failed.

I don’t have any “important looking” check boxes in my VS 2015 “Modify” UI, but I would be willing to try a more specific target.

An easy check I found is this: Open VS 2015. Can you make a C++ Win32 console application? If the option is there, then you probably have the C++ tools installed already. If not, that may be the issue.

You may already have, but look over the node-gyp documentation for setup and such. Node-gyp is the actual thing doing the compiling, and there are a few extra steps in setting up node-gyp on Windows like setting the config for VS version.

I don’t know much about the msbuild package, and could not get that to work myself either. If I were to guess, it may be something weird with node-gyp defaulting to VS if it exists. So even if the msbuild thing is installed, node-gyp goes to VS anyway. That’s just pure speculation on my end though.

jkong: Much thanks! That fixed it. It was also the most excellent way to determine whether I had the C++ installed, because you sure don’t get very far if you don’t.

In Windows 10 x64
I’m installed.

Manually ms build tools
Visual studio 2015
meteor npm install --global --production windows-build-tools in powershell

NONE OF THEM WORKED !!!

=> Errors while adding packages:

While loading package npm-bcrypt@0.8.7:
error: Command failed:
C:\Users\GaDo\AppData\Local.meteor\packages\meteor-tool\1.4.0-1\mt-os.windows.x86_32\dev_bundle\bin\npm.cmd
rebuild --no-bin-links --update-binary
gyp ERR! build error
gyp ERR! stack Error: C:\Program Files (x86)\MSBuild\14.0\bin\msbuild.exe failed with exit code: 1
gyp ERR! stack at ChildProcess.onExit
(C:\Users\GaDo\AppData\Local.meteor\packages\meteor-tool\1.4.0-1\mt-os.windows.x86_32\dev_bundle\lib\node_modules\node-gyp\lib\build.js:276:23)
gyp ERR! stack at emitTwo (events.js:87:13)
gyp ERR! stack at ChildProcess.emit (events.js:172:7)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:200:12)
gyp ERR! System Windows_NT 10.0.10586
gyp ERR! command
"C:\Users\GaDo\AppData\Local\.meteor\packages\meteor-tool\1.4.0-1\mt-os.windows.x86_32\dev_bundle\bin\node.exe"
“C:\Users\GaDo\AppData\Local\.meteor\packages\meteor-tool\1.4.0-1\mt-os.windows.x86_32\dev_bundle\lib\node_modules\node-gyp\bin\node-gyp.js”
"rebuild"
gyp ERR! cwd
C:\Users\GaDo\AppData\Local.meteor\packages\npm-bcrypt\0.8.7\npm\node_modules.temp-aynbxh\node_modules\bcrypt
gyp ERR! node -v v4.4.7
gyp ERR! node-gyp -v v3.4.0
gyp ERR! not ok

npm ERR! Windows_NT 10.0.10586
npm ERR! argv
"C:\Users\GaDo\AppData\Local\.meteor\packages\meteor-tool\1.4.0-1\mt-os.windows.x86_32\dev_bundle\bin\node.exe"
“C:\Users\GaDo\AppData\Local\.meteor\packages\meteor-tool\1.4.0-1\mt-os.windows.x86_32\dev_bundle\lib\node_modules\npm\bin\npm-cli.js”
“rebuild” “–no-bin-links” "–update-binary"
npm ERR! node v4.4.7
npm ERR! npm v3.10.5
npm ERR! code ELIFECYCLE
npm ERR! bcrypt@0.8.7 install: node-gyp rebuild
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the bcrypt@0.8.7 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 bcrypt 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 bcrypt
npm ERR! Or if that isn’t available, you can get their info via:
npm ERR! npm owner ls bcrypt
npm ERR! There is likely additional logging output above.

npm ERR! Please include the following file with any support request:
npm ERR!
C:\Users\GaDo\AppData\Local.meteor\packages\npm-bcrypt\0.8.7\npm\node_modules.temp-aynbxh\npm-debug.log
gyp ERR! build error
gyp ERR! stack Error: C:\Program Files (x86)\MSBuild\14.0\bin\msbuild.exe failed with exit code: 1
gyp ERR! stack at ChildProcess.onExit
(C:\Users\GaDo\AppData\Local.meteor\packages\meteor-tool\1.4.0-1\mt-os.windows.x86_32\dev_bundle\lib\node_modules\node-gyp\lib\build.js:276:23)
gyp ERR! stack at emitTwo (events.js:87:13)
gyp ERR! stack at ChildProcess.emit (events.js:172:7)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:200:12)
gyp ERR! System Windows_NT 10.0.10586
gyp ERR! command
"C:\Users\GaDo\AppData\Local\.meteor\packages\meteor-tool\1.4.0-1\mt-os.windows.x86_32\dev_bundle\bin\node.exe"
“C:\Users\GaDo\AppData\Local\.meteor\packages\meteor-tool\1.4.0-1\mt-os.windows.x86_32\dev_bundle\lib\node_modules\node-gyp\bin\node-gyp.js”
"rebuild"
gyp ERR! cwd
C:\Users\GaDo\AppData\Local.meteor\packages\npm-bcrypt\0.8.7\npm\node_modules.temp-aynbxh\node_modules\bcrypt
gyp ERR! node -v v4.4.7
gyp ERR! node-gyp -v v3.4.0
gyp ERR! not ok

npm ERR! Windows_NT 10.0.10586
npm ERR! argv
"C:\Users\GaDo\AppData\Local\.meteor\packages\meteor-tool\1.4.0-1\mt-os.windows.x86_32\dev_bundle\bin\node.exe"
“C:\Users\GaDo\AppData\Local\.meteor\packages\meteor-tool\1.4.0-1\mt-os.windows.x86_32\dev_bundle\lib\node_modules\npm\bin\npm-cli.js”
“rebuild” “–no-bin-links” "–update-binary"
npm ERR! node v4.4.7
npm ERR! npm v3.10.5
npm ERR! code ELIFECYCLE
npm ERR! bcrypt@0.8.7 install: node-gyp rebuild
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the bcrypt@0.8.7 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 bcrypt 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 bcrypt
npm ERR! Or if that isn’t available, you can get their info via:
npm ERR! npm owner ls bcrypt
npm ERR! There is likely additional logging output above.

npm ERR! Please include the following file with any support request:
npm ERR!
C:\Users\GaDo\AppData\Local.meteor\packages\npm-bcrypt\0.8.7\npm\node_modules.temp-aynbxh\npm-debug.log

I’m really tired of this error. I’m considering comeback to Laravel for this. Can you help me with a solution, please?

Thanks jkong and jgg. I opened VS 2015 and downloaded the C++ tools directly through VS.

I used cmd and power shell with ‘meteor npm install --global --production windows-build-tools’ with no positive results. Could not add accounts-password. So I downloaded and executed windows-build-tools directly from official microsoft Download Center and in less than 5 minutes could add the accounts-password package.