I got an error when I ran meteor add accounts-password and got hooked

problem

$ meteor add accounts-password

I get an error when I run, re-install npm or update python to the latest version meteor add npm-bcrypt I tried various things and tried various things, but I couldn't do it, but as a result, it was caused by a rudimentary mistake. Stack Overflow also got a similar error in another case, so I think there are many similar situations.

environment

Mac OS X El Capitan 10.11.6 node 4.5.0 node-gyp 3.4.0 Python 2.7.12

Conclusion (in my case)

$ sudo chown -R [My username]:staff /Users/[My username]/[Where the Meteor project is]/.meteor/local/

I became partly root with owner privileges, so I fixed it when I made my user the owner.

/Users/nobu/Documents/programs/microscope/.meteor/local//plugin-cache/accounts-password/1.0.1
/Users/nobu/Documents/programs/microscope/.meteor/local//plugin-cache/accounts-password
/Users/nobu/Documents/programs/microscope/.meteor/local//plugin-cache/email/1.0.16
/Users/nobu/Documents/programs/microscope/.meteor/local//plugin-cache/email
/Users/nobu/Documents/programs/microscope/.meteor/local//plugin-cache/npm-bcrypt/0.7.7
/Users/nobu/Documents/programs/microscope/.meteor/local//plugin-cache/npm-bcrypt
/Users/nobu/Documents/programs/microscope/.meteor/local//plugin-cache/sha/1.0.8
/Users/nobu/Documents/programs/microscope/.meteor/local//plugin-cache/sha
/Users/nobu/Documents/programs/microscope/.meteor/local//plugin-cache/srp/1.0.9
/Users/nobu/Documents/programs/microscope/.meteor/local//plugin-cache/srp

Their privileges are now root: staff. I think I sudoed it when I added it.

error contents

Console output


Shirahama-no-MacBook-Pro:microscope nobu$ meteor add accounts-password
 => Errors while adding packages:

While loading package [email protected]:
error: Command failed:
/Users/nobu/.meteor/packages/meteor-tool/.1.4.1_1.1h0re2h++os.osx.x86_64+web.browser+web.cordova/mt-os.osx.x86_64/dev_bundle/bin/npm
rebuild --no-bin-links --update-binary
../src/bcrypt_node.cc:118:18: error: no member named 'Dispose' in 'v8::Persistent<v8::Function,
v8::NonCopyablePersistentTraits<v8::Function> >'
callback.Dispose();
~~~~~~~~ ^
../src/bcrypt_node.cc:202:19: error: unknown type name 'uv_work_t'
void GenSaltAsync(uv_work_t* req) {
^
../src/bcrypt_node.cc:219:24: error: unknown type name 'uv_work_t'
void GenSaltAsyncAfter(uv_work_t* req) {
^
../src/bcrypt_node.cc:220:17: error: calling a protected constructor of class 'v8::HandleScope'
HandleScope scope;
^
/Users/nobu/.node-gyp/4.5.0/include/node/v8.h:885:13: note: declared protected here
V8_INLINE HandleScope() {}
^
../src/bcrypt_node.cc:228:44: error: no member named 'New' in 'v8::String'
argv[0] = Exception::Error(String::New(baton->error.c_str()));
~~~~~~~~^
../src/bcrypt_node.cc:229:19: error: no matching function for call to 'Undefined'
argv[1] = Undefined();
^~~~~~~~~
/Users/nobu/.node-gyp/4.5.0/include/node/v8.h:315:27: note: candidate function not viable: requires
single argument 'isolate', but no arguments were provided
friend Local<Primitive> Undefined(Isolate* isolate);
^
../src/bcrypt_node.cc:232:19: error: no matching function for call to 'Undefined'
argv[0] = Undefined();
^~~~~~~~~
/Users/nobu/.node-gyp/4.5.0/include/node/v8.h:315:27: note: candidate function not viable: requires
single argument 'isolate', but no arguments were provided
friend Local<Primitive> Undefined(Isolate* isolate);
^
../src/bcrypt_node.cc:233:19: warning: 'Encode' is deprecated: Use Encode(isolate, ...)
[-Wdeprecated-declarations]
argv[1] = Encode(baton->salt.c_str(), baton->salt.size(), BINARY);
^
/Users/nobu/.node-gyp/4.5.0/include/node/node.h:300:45: note: 'Encode' has been explicitly marked
deprecated here
inline v8::Local<v8::Value> Encode(
^
../src/bcrypt_node.cc:238:20: error: member reference type 'v8::Persistent<v8::Function>' is not a
pointer; did you mean to use '.'?
baton->callback->Call(Context::GetCurrent()->Global(), 2, argv);
~~~~~~~~~~~~~~~^~
.
../src/bcrypt_node.cc:238:22: error: no member named 'Call' in 'v8::Persistent<v8::Function,
v8::NonCopyablePersistentTraits<v8::Function> >'
baton->callback->Call(Context::GetCurrent()->Global(), 2, argv);
~~~~~~~~~~~~~~~  ^
../src/bcrypt_node.cc:238:36: error: no member named 'GetCurrent' in 'v8::Context'
baton->callback->Call(Context::GetCurrent()->Global(), 2, argv);
~~~~~~~~~^
../src/bcrypt_node.cc:241:9: warning: 'FatalException' is deprecated: Use FatalException(isolate, ...)
[-Wdeprecated-declarations]
FatalException(try_catch);
^
/Users/nobu/.node-gyp/4.5.0/include/node/node.h:284:29: note: 'FatalException' has been explicitly
marked deprecated here
inline void FatalException(const v8::TryCatch& try_catch) {
^
../src/bcrypt_node.cc:246:34: error: unknown type name 'Arguments'; did you mean
'v8::internal::Arguments'?
Handle<Value> GenerateSalt(const Arguments &args) {
^~~~~~~~~
v8::internal::Arguments
/Users/nobu/.node-gyp/4.5.0/include/node/v8.h:139:7: note: 'v8::internal::Arguments' declared here
class Arguments;
^
../src/bcrypt_node.cc:247:17: error: calling a protected constructor of class 'v8::HandleScope'
HandleScope scope;
^
/Users/nobu/.node-gyp/4.5.0/include/node/v8.h:885:13: note: declared protected here
V8_INLINE HandleScope() {}
^
../src/bcrypt_node.cc:249:32: error: type 'const v8::internal::Arguments' does not provide a subscript
operator
const ssize_t rounds = args[0]->Int32Value();
~~~~^~
../src/bcrypt_node.cc:250:30: error: type 'const v8::internal::Arguments' does not provide a subscript
operator
const int rand_len = args[1]->Int32Value();
~~~~^~
../src/bcrypt_node.cc:251:58: error: type 'const v8::internal::Arguments' does not provide a subscript
operator
Local<Function> callback =
Local<Function>::Cast(args[2]);
~~~~^~
../src/bcrypt_node.cc:255:45: error: 'New' is a private member of
'v8::PersistentBase<v8::Function>'
baton->callback = Persistent<Function>::New(callback);
^
/Users/nobu/.node-gyp/4.5.0/include/node/v8.h:639:23: note: declared private here
V8_INLINE static T* New(Isolate* isolate, T* that);
^
../src/bcrypt_node.cc:255:57: error: too few arguments to function call, expected 2, have 1
baton->callback = Persistent<Function>::New(callback);
~~~~~~~~~~~~~~~~~~~~~~~~~         ^
/Users/nobu/.node-gyp/4.5.0/include/node/v8.h:639:3: note: 'New' declared here
V8_INLINE static T* New(Isolate* isolate, T* that);
^
/Users/nobu/.node-gyp/4.5.0/include/node/v8config.h:301:20: note: expanded from macro 'V8_INLINE'
# define V8_INLINE inline __attribute__((always_inline))
^
../src/bcrypt_node.cc:259:5: error: unknown type name 'uv_work_t'
uv_work_t* req = new uv_work_t;
^
../src/bcrypt_node.cc:259:26: error: unknown type name 'uv_work_t'
uv_work_t* req = new uv_work_t;
^
fatal error: too many errors emitted, stopping now [-ferror-limit=]
2 warnings and 20 errors generated.
make: *** [Release/obj.target/bcrypt_lib/src/bcrypt_node.o] Error 1
gyp ERR! build error
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack     at ChildProcess.onExit
(/Users/nobu/.meteor/packages/meteor-tool/.1.4.1_1.1h0re2h++os.osx.x86_64+web.browser+web.cordova/mt-os.osx.x86_64/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 Darwin 15.6.0
gyp ERR! command
"/Users/nobu/.meteor/packages/meteor-tool/.1.4.1_1.1h0re2h++os.osx.x86_64+web.browser+web.cordova/mt-os.osx.x86_64/dev_bundle/bin/node"
"/Users/nobu/.meteor/packages/meteor-tool/.1.4.1_1.1h0re2h++os.osx.x86_64+web.browser+web.cordova/mt-os.osx.x86_64/dev_bundle/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js"
"rebuild"
gyp ERR! cwd
/Users/nobu/.meteor/packages/npm-bcrypt/.0.7.7.f9cvr9++os.osx.x86_64+web.browser+web.cordova/npm/node_modules/.temp-1h94ra8/node_modules/bcrypt
gyp ERR! node -v v4.5.0
gyp ERR! node-gyp -v v3.4.0
gyp ERR! not ok

npm ERR! Darwin 15.6.0
npm ERR! argv
"/Users/nobu/.meteor/packages/meteor-tool/.1.4.1_1.1h0re2h++os.osx.x86_64+web.browser+web.cordova/mt-os.osx.x86_64/dev_bundle/bin/node"
"/Users/nobu/.meteor/packages/meteor-tool/.1.4.1_1.1h0re2h++os.osx.x86_64+web.browser+web.cordova/mt-os.osx.x86_64/dev_bundle/bin/npm"
"rebuild" "--no-bin-links" "--update-binary"
npm ERR! node v4.5.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 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!
/Users/nobu/.meteor/packages/npm-bcrypt/.0.7.7.f9cvr9++os.osx.x86_64+web.browser+web.cordova/npm/node_modules/.temp-1h94ra8/npm-debug.log
../src/bcrypt_node.cc:118:18: error: no member named 'Dispose' in 'v8::Persistent<v8::Function,
v8::NonCopyablePersistentTraits<v8::Function> >'
callback.Dispose();
~~~~~~~~ ^
../src/bcrypt_node.cc:202:19: error: unknown type name 'uv_work_t'
void GenSaltAsync(uv_work_t* req) {
^
../src/bcrypt_node.cc:219:24: error: unknown type name 'uv_work_t'
void GenSaltAsyncAfter(uv_work_t* req) {
^
../src/bcrypt_node.cc:220:17: error: calling a protected constructor of class 'v8::HandleScope'
HandleScope scope;
^
/Users/nobu/.node-gyp/4.5.0/include/node/v8.h:885:13: note: declared protected here
V8_INLINE HandleScope() {}
^
../src/bcrypt_node.cc:228:44: error: no member named 'New' in 'v8::String'
argv[0] = Exception::Error(String::New(baton->error.c_str()));
~~~~~~~~^
../src/bcrypt_node.cc:229:19: error: no matching function for call to 'Undefined'
argv[1] = Undefined();
^~~~~~~~~
/Users/nobu/.node-gyp/4.5.0/include/node/v8.h:315:27: note: candidate function not viable: requires
single argument 'isolate', but no arguments were provided
friend Local<Primitive> Undefined(Isolate* isolate);
^
../src/bcrypt_node.cc:232:19: error: no matching function for call to 'Undefined'
argv[0] = Undefined();
^~~~~~~~~
/Users/nobu/.node-gyp/4.5.0/include/node/v8.h:315:27: note: candidate function not viable: requires
single argument 'isolate', but no arguments were provided
friend Local<Primitive> Undefined(Isolate* isolate);
^
../src/bcrypt_node.cc:233:19: warning: 'Encode' is deprecated: Use Encode(isolate, ...)
[-Wdeprecated-declarations]
argv[1] = Encode(baton->salt.c_str(), baton->salt.size(), BINARY);
^
/Users/nobu/.node-gyp/4.5.0/include/node/node.h:300:45: note: 'Encode' has been explicitly marked
deprecated here
inline v8::Local<v8::Value> Encode(
^
../src/bcrypt_node.cc:238:20: error: member reference type 'v8::Persistent<v8::Function>' is not a
pointer; did you mean to use '.'?
baton->callback->Call(Context::GetCurrent()->Global(), 2, argv);
~~~~~~~~~~~~~~~^~
.
../src/bcrypt_node.cc:238:22: error: no member named 'Call' in 'v8::Persistent<v8::Function,
v8::NonCopyablePersistentTraits<v8::Function> >'
baton->callback->Call(Context::GetCurrent()->Global(), 2, argv);
~~~~~~~~~~~~~~~  ^
../src/bcrypt_node.cc:238:36: error: no member named 'GetCurrent' in 'v8::Context'
baton->callback->Call(Context::GetCurrent()->Global(), 2, argv);
~~~~~~~~~^
../src/bcrypt_node.cc:241:9: warning: 'FatalException' is deprecated: Use FatalException(isolate, ...)
[-Wdeprecated-declarations]
FatalException(try_catch);
^
/Users/nobu/.node-gyp/4.5.0/include/node/node.h:284:29: note: 'FatalException' has been explicitly
marked deprecated here
inline void FatalException(const v8::TryCatch& try_catch) {
^
../src/bcrypt_node.cc:246:34: error: unknown type name 'Arguments'; did you mean
'v8::internal::Arguments'?
Handle<Value> GenerateSalt(const Arguments &args) {
^~~~~~~~~
v8::internal::Arguments
/Users/nobu/.node-gyp/4.5.0/include/node/v8.h:139:7: note: 'v8::internal::Arguments' declared here
class Arguments;
^
../src/bcrypt_node.cc:247:17: error: calling a protected constructor of class 'v8::HandleScope'
HandleScope scope;
^
/Users/nobu/.node-gyp/4.5.0/include/node/v8.h:885:13: note: declared protected here
V8_INLINE HandleScope() {}
^
../src/bcrypt_node.cc:249:32: error: type 'const v8::internal::Arguments' does not provide a subscript
operator
const ssize_t rounds = args[0]->Int32Value();
~~~~^~
../src/bcrypt_node.cc:250:30: error: type 'const v8::internal::Arguments' does not provide a subscript
operator
const int rand_len = args[1]->Int32Value();
~~~~^~
../src/bcrypt_node.cc:251:58: error: type 'const v8::internal::Arguments' does not provide a subscript
operator
Local<Function> callback =
Local<Function>::Cast(args[2]);
~~~~^~
../src/bcrypt_node.cc:255:45: error: 'New' is a private member of
'v8::PersistentBase<v8::Function>'
baton->callback = Persistent<Function>::New(callback);
^
/Users/nobu/.node-gyp/4.5.0/include/node/v8.h:639:23: note: declared private here
V8_INLINE static T* New(Isolate* isolate, T* that);
^
../src/bcrypt_node.cc:255:57: error: too few arguments to function call, expected 2, have 1
baton->callback = Persistent<Function>::New(callback);
~~~~~~~~~~~~~~~~~~~~~~~~~         ^
/Users/nobu/.node-gyp/4.5.0/include/node/v8.h:639:3: note: 'New' declared here
V8_INLINE static T* New(Isolate* isolate, T* that);
^
/Users/nobu/.node-gyp/4.5.0/include/node/v8config.h:301:20: note: expanded from macro 'V8_INLINE'
# define V8_INLINE inline __attribute__((always_inline))
^
../src/bcrypt_node.cc:259:5: error: unknown type name 'uv_work_t'
uv_work_t* req = new uv_work_t;
^
../src/bcrypt_node.cc:259:26: error: unknown type name 'uv_work_t'
uv_work_t* req = new uv_work_t;
^
fatal error: too many errors emitted, stopping now [-ferror-limit=]
2 warnings and 20 errors generated.
make: *** [Release/obj.target/bcrypt_lib/src/bcrypt_node.o] Error 1
gyp ERR! build error
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack     at ChildProcess.onExit
(/Users/nobu/.meteor/packages/meteor-tool/.1.4.1_1.1h0re2h++os.osx.x86_64+web.browser+web.cordova/mt-os.osx.x86_64/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 Darwin 15.6.0
gyp ERR! command
"/Users/nobu/.meteor/packages/meteor-tool/.1.4.1_1.1h0re2h++os.osx.x86_64+web.browser+web.cordova/mt-os.osx.x86_64/dev_bundle/bin/node"
"/Users/nobu/.meteor/packages/meteor-tool/.1.4.1_1.1h0re2h++os.osx.x86_64+web.browser+web.cordova/mt-os.osx.x86_64/dev_bundle/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js"
"rebuild"
gyp ERR! cwd
/Users/nobu/.meteor/packages/npm-bcrypt/.0.7.7.f9cvr9++os.osx.x86_64+web.browser+web.cordova/npm/node_modules/.temp-1h94ra8/node_modules/bcrypt
gyp ERR! node -v v4.5.0
gyp ERR! node-gyp -v v3.4.0
gyp ERR! not ok

npm ERR! Darwin 15.6.0
npm ERR! argv
"/Users/nobu/.meteor/packages/meteor-tool/.1.4.1_1.1h0re2h++os.osx.x86_64+web.browser+web.cordova/mt-os.osx.x86_64/dev_bundle/bin/node"
"/Users/nobu/.meteor/packages/meteor-tool/.1.4.1_1.1h0re2h++os.osx.x86_64+web.browser+web.cordova/mt-os.osx.x86_64/dev_bundle/bin/npm"
"rebuild" "--no-bin-links" "--update-binary"
npm ERR! node v4.5.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 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!
/Users/nobu/.meteor/packages/npm-bcrypt/.0.7.7.f9cvr9++os.osx.x86_64+web.browser+web.cordova/npm/node_modules/.temp-1h94ra8/npm-debug.log




Shirahama-no-MacBook-Pro:microscope nobu$ node-gyp rebuild
gyp info it worked if it ends with ok
gyp info using [email protected]
gyp info using [email protected] | darwin | x64
gyp info spawn /usr/bin/python
gyp info spawn args [ '/usr/local/lib/node_modules/node-gyp/gyp/gyp_main.py',
gyp info spawn args   'binding.gyp',
gyp info spawn args   '-f',
gyp info spawn args   'make',
gyp info spawn args   '-I',
gyp info spawn args   '/Users/nobu/Documents/programs/microscope/build/config.gypi',
gyp info spawn args   '-I',
gyp info spawn args   '/usr/local/lib/node_modules/node-gyp/addon.gypi',
gyp info spawn args   '-I',
gyp info spawn args   '/Users/nobu/.node-gyp/4.5.0/include/node/common.gypi',
gyp info spawn args   '-Dlibrary=shared_library',
gyp info spawn args   '-Dvisibility=default',
gyp info spawn args   '-Dnode_root_dir=/Users/nobu/.node-gyp/4.5.0',
gyp info spawn args   '-Dnode_gyp_dir=/usr/local/lib/node_modules/node-gyp',
gyp info spawn args   '-Dnode_lib_file=node.lib',
gyp info spawn args   '-Dmodule_root_dir=/Users/nobu/Documents/programs/microscope',
gyp info spawn args   '--depth=.',
gyp info spawn args   '--no-parallel',
gyp info spawn args   '--generator-output',
gyp info spawn args   'build',
gyp info spawn args   '-Goutput_dir=.' ]
gyp: binding.gyp not found (cwd: /Users/nobu/Documents/programs/microscope) while trying to load binding.gyp
gyp ERR! configure error
gyp ERR! stack Error: `gyp` failed with exit code: 1
gyp ERR! stack     at ChildProcess.onCpExit (/usr/local/lib/node_modules/node-gyp/lib/configure.js:305:16)
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 Darwin 15.6.0
gyp ERR! command "/Users/nobu/.nodebrew/node/v4.5.0/bin/node" "/usr/local/bin/node-gyp" "rebuild"
gyp ERR! cwd /Users/nobu/Documents/programs/microscope
gyp ERR! node -v v4.5.0
gyp ERR! node-gyp -v v3.4.0
gyp ERR! not ok

Recommended Posts

I got an error when I ran meteor add accounts-password and got hooked
I got an error when I ran composer global require laravel / installer
I got an error when saving with OpenCV
I got an error when trying to install Xgboost and its solution
I got an error when using Tensorboard with Pytorch
I got an error in vim and zsh in Python 3.7 series
When I installed python on macOS and used it, I got an error when I put an https connection
When I get an error with PyInstaller
I got an error when trying to run Hello World in Go language
I got an error when I put opencv in python3 with Raspberry Pi [Remedy]
Linux Ubuntu16.04 I got a little scary error when I ran a command using sudo
I got an error that Python couldn't read settings.ini
I get an error when I put opencv in pyautoGUI
I get an error when trying meinheld + WebSocket + mongodb
psql: I ran into an error with an invalid option --'''.
I got an error when pip install pandas on Mac, so I dealt with it
I got an error when pip install tweepy on macOS Sierra, so I dealt with it
I got a Value Error when using JUMAN ++ with PyKNP
I got an error when I tried to process luigi in parallel on windows, but the solution
I got an SSL Error when I installed Anaconda in a new environment, so I solved it (Windows10, Anaconda3-2019.10)
I got an AttributeError when mocking the open method in python
When I get an error with Pylint in Atom on Windows
I get an error when trying to install maec 4.0.1.0 with pip
I got an SSL related error with pip install, so I solved it
I got an unfamiliar error in Django: TypeError: resolve () got an unexpected keyword argument'strict'