2

I need to install an npm package on my computer, which has a dependency on the package "scrypt". When installing, the build fails due to this dependency. Now, im looking to resolve this error, first (obvious) idea being to install the scrypt-package separately.

Some info for the environment: I am running MacOS X 10.15.6 and npm 6.14.6. My GCC is

Apple clang version 11.0.3 (clang-1103.0.32.62)
Target: x86_64-apple-darwin19.6.0

Heres what happens when I try to install the package:

npm install -g scrypt

> scrypt@6.0.3 preinstall /usr/local/lib/node_modules/scrypt
> node node-scrypt-preinstall.js


> scrypt@6.0.3 install /usr/local/lib/node_modules/scrypt
> node-gyp rebuild

  SOLINK_MODULE(target) Release/copied_files.node
  CC(target) Release/obj.target/scrypt_wrapper/src/util/memlimit.o
  CC(target) Release/obj.target/scrypt_wrapper/src/scryptwrapper/keyderivation.o
  CC(target) Release/obj.target/scrypt_wrapper/src/scryptwrapper/pickparams.o
  CC(target) Release/obj.target/scrypt_wrapper/src/scryptwrapper/hash.o
  LIBTOOL-STATIC Release/scrypt_wrapper.a
  CC(target) Release/obj.target/scrypt_lib/scrypt/scrypt-1.2.0/lib/crypto/crypto_scrypt.o
  CC(target) Release/obj.target/scrypt_lib/scrypt/scrypt-1.2.0/lib/crypto/crypto_scrypt_smix.o
  CC(target) Release/obj.target/scrypt_lib/scrypt/scrypt-1.2.0/libcperciva/util/warnp.o
  CC(target) Release/obj.target/scrypt_lib/scrypt/scrypt-1.2.0/libcperciva/alg/sha256.o
  CC(target) Release/obj.target/scrypt_lib/scrypt/scrypt-1.2.0/libcperciva/util/insecure_memzero.o
  CC(target) Release/obj.target/scrypt_lib/scrypt/scrypt-1.2.0/lib/scryptenc/scryptenc_cpuperf.o
  LIBTOOL-STATIC Release/scrypt_lib.a
  CXX(target) Release/obj.target/scrypt/src/node-boilerplate/scrypt_common.o
  CXX(target) Release/obj.target/scrypt/src/node-boilerplate/scrypt_params_async.o
In file included from ../src/node-boilerplate/scrypt_params_async.cc:4:
In file included from ../src/node-boilerplate/inc/scrypt_params_async.h:28:
In file included from ../src/node-boilerplate/inc/scrypt_async.h:28:
../src/node-boilerplate/inc/scrypt_common.h:39:14: error: no matching member function for call to 'Get'
      N(obj->Get(Nan::New("N").ToLocalChecked())->Uint32Value()),
        ~~~~~^~~
/Users/xyz/Library/Caches/node-gyp/14.5.0/include/node/v8.h:3713:43: note: candidate function not viable: requires 2 arguments, but 1 was provided
  V8_WARN_UNUSED_RESULT MaybeLocal<Value> Get(Local<Context> context,
                                          ^
/Users/xyz/Library/Caches/node-gyp/14.5.0/include/node/v8.h:3716:43: note: candidate function not viable: requires 2 arguments, but 1 was provided
  V8_WARN_UNUSED_RESULT MaybeLocal<Value> Get(Local<Context> context,
                                          ^
In file included from ../src/node-boilerplate/scrypt_params_async.cc:4:
In file included from ../src/node-boilerplate/inc/scrypt_params_async.h:28:
In file included from ../src/node-boilerplate/inc/scrypt_async.h:28:
../src/node-boilerplate/inc/scrypt_common.h:40:14: error: no matching member function for call to 'Get'
      r(obj->Get(Nan::New("r").ToLocalChecked())->Uint32Value()),
        ~~~~~^~~
/Users/xyz/Library/Caches/node-gyp/14.5.0/include/node/v8.h:3713:43: note: candidate function not viable: requires 2 arguments, but 1 was provided
  V8_WARN_UNUSED_RESULT MaybeLocal<Value> Get(Local<Context> context,
                                          ^
/Users/xyz/Library/Caches/node-gyp/14.5.0/include/node/v8.h:3716:43: note: candidate function not viable: requires 2 arguments, but 1 was provided
  V8_WARN_UNUSED_RESULT MaybeLocal<Value> Get(Local<Context> context,
                                          ^
In file included from ../src/node-boilerplate/scrypt_params_async.cc:4:
In file included from ../src/node-boilerplate/inc/scrypt_params_async.h:28:
In file included from ../src/node-boilerplate/inc/scrypt_async.h:28:
../src/node-boilerplate/inc/scrypt_common.h:41:14: error: no matching member function for call to 'Get'
      p(obj->Get(Nan::New("p").ToLocalChecked())->Uint32Value()) {}
        ~~~~~^~~
/Users/xyz/Library/Caches/node-gyp/14.5.0/include/node/v8.h:3713:43: note: candidate function not viable: requires 2 arguments, but 1 was provided
  V8_WARN_UNUSED_RESULT MaybeLocal<Value> Get(Local<Context> context,
                                          ^
/Users/xyz/Library/Caches/node-gyp/14.5.0/include/node/v8.h:3716:43: note: candidate function not viable: requires 2 arguments, but 1 was provided
  V8_WARN_UNUSED_RESULT MaybeLocal<Value> Get(Local<Context> context,
                                          ^
In file included from ../src/node-boilerplate/scrypt_params_async.cc:4:
In file included from ../src/node-boilerplate/inc/scrypt_params_async.h:28:
../src/node-boilerplate/inc/scrypt_async.h:53:17: warning: 'Call' is deprecated [-Wdeprecated-declarations]
      callback->Call(1, argv);
                ^
../node_modules/nan/nan.h:1741:3: note: 'Call' has been explicitly marked deprecated here
  NAN_DEPRECATED inline v8::Local<v8::Value>
  ^
../node_modules/nan/nan.h:106:40: note: expanded from macro 'NAN_DEPRECATED'
# define NAN_DEPRECATED __attribute__((deprecated))
                                       ^
In file included from ../src/node-boilerplate/scrypt_params_async.cc:4:
../src/node-boilerplate/inc/scrypt_params_async.h:35:36: error: too few arguments to function call, single argument 'context' was not specified
      maxtime(info[0]->NumberValue()),
              ~~~~~~~~~~~~~~~~~~~~ ^
/Users/xyz/Library/Caches/node-gyp/14.5.0/include/node/v8.h:2857:3: note: 'NumberValue' declared here
  V8_WARN_UNUSED_RESULT Maybe<double> NumberValue(Local<Context> context) const;
  ^
/Users/xyz/Library/Caches/node-gyp/14.5.0/include/node/v8config.h:422:31: note: expanded from macro 'V8_WARN_UNUSED_RESULT'
#define V8_WARN_UNUSED_RESULT __attribute__((warn_unused_result))
                              ^
In file included from ../src/node-boilerplate/scrypt_params_async.cc:4:
../src/node-boilerplate/inc/scrypt_params_async.h:36:39: error: too few arguments to function call, single argument 'context' was not specified
      maxmemfrac(info[1]->NumberValue()),
                 ~~~~~~~~~~~~~~~~~~~~ ^
/Users/sebastian/Library/Caches/node-gyp/14.5.0/include/node/v8.h:2857:3: note: 'NumberValue' declared here
  V8_WARN_UNUSED_RESULT Maybe<double> NumberValue(Local<Context> context) const;
  ^
/Users/xyz/Library/Caches/node-gyp/14.5.0/include/node/v8config.h:422:31: note: expanded from macro 'V8_WARN_UNUSED_RESULT'
#define V8_WARN_UNUSED_RESULT __attribute__((warn_unused_result))
                              ^
In file included from ../src/node-boilerplate/scrypt_params_async.cc:4:
../src/node-boilerplate/inc/scrypt_params_async.h:37:36: error: too few arguments to function call, single argument 'context' was not specified
      maxmem(info[2]->IntegerValue()),
             ~~~~~~~~~~~~~~~~~~~~~ ^
/Users/xyz/Library/Caches/node-gyp/14.5.0/include/node/v8.h:2859:3: note: 'IntegerValue' declared here
  V8_WARN_UNUSED_RESULT Maybe<int64_t> IntegerValue(
  ^
/Users/xyz/Library/Caches/node-gyp/14.5.0/include/node/v8config.h:422:31: note: expanded from macro 'V8_WARN_UNUSED_RESULT'
#define V8_WARN_UNUSED_RESULT __attribute__((warn_unused_result))
                              ^
In file included from ../src/node-boilerplate/scrypt_params_async.cc:4:
../src/node-boilerplate/inc/scrypt_params_async.h:38:39: error: too few arguments to function call, single argument 'context' was not specified
      osfreemem(info[3]->IntegerValue())
                ~~~~~~~~~~~~~~~~~~~~~ ^
/Users/xyz/Library/Caches/node-gyp/14.5.0/include/node/v8.h:2859:3: note: 'IntegerValue' declared here
  V8_WARN_UNUSED_RESULT Maybe<int64_t> IntegerValue(
  ^
/Users/xyz/Library/Caches/node-gyp/14.5.0/include/node/v8config.h:422:31: note: expanded from macro 'V8_WARN_UNUSED_RESULT'
#define V8_WARN_UNUSED_RESULT __attribute__((warn_unused_result))
                              ^
../src/node-boilerplate/scrypt_params_async.cc:23:8: error: no matching member function for call to 'Set'
  obj->Set(Nan::New("N").ToLocalChecked(), Nan::New<Integer>(logN));
  ~~~~~^~~
/Users/xyz/Library/Caches/node-gyp/14.5.0/include/node/v8.h:3666:37: note: candidate function not viable: requires 3 arguments, but 2 were provided
  V8_WARN_UNUSED_RESULT Maybe<bool> Set(Local<Context> context,
                                    ^
/Users/xyz/Library/Caches/node-gyp/14.5.0/include/node/v8.h:3669:37: note: candidate function not viable: requires 3 arguments, but 2 were provided
  V8_WARN_UNUSED_RESULT Maybe<bool> Set(Local<Context> context, uint32_t index,
                                    ^
../src/node-boilerplate/scrypt_params_async.cc:24:8: error: no matching member function for call to 'Set'
  obj->Set(Nan::New("r").ToLocalChecked(), Nan::New<Integer>(r));
  ~~~~~^~~
/Users/xyz/Library/Caches/node-gyp/14.5.0/include/node/v8.h:3666:37: note: candidate function not viable: requires 3 arguments, but 2 were provided
  V8_WARN_UNUSED_RESULT Maybe<bool> Set(Local<Context> context,
                                    ^
/Users/xyz/Library/Caches/node-gyp/14.5.0/include/node/v8.h:3669:37: note: candidate function not viable: requires 3 arguments, but 2 were provided
  V8_WARN_UNUSED_RESULT Maybe<bool> Set(Local<Context> context, uint32_t index,
                                    ^
../src/node-boilerplate/scrypt_params_async.cc:25:8: error: no matching member function for call to 'Set'
  obj->Set(Nan::New("p").ToLocalChecked(), Nan::New<Integer>(p));
  ~~~~~^~~
/Users/xyz/Library/Caches/node-gyp/14.5.0/include/node/v8.h:3666:37: note: candidate function not viable: requires 3 arguments, but 2 were provided
  V8_WARN_UNUSED_RESULT Maybe<bool> Set(Local<Context> context,
                                    ^
/Users/xyz/Library/Caches/node-gyp/14.5.0/include/node/v8.h:3669:37: note: candidate function not viable: requires 3 arguments, but 2 were provided
  V8_WARN_UNUSED_RESULT Maybe<bool> Set(Local<Context> context, uint32_t index,
                                    ^
../src/node-boilerplate/scrypt_params_async.cc:32:13: warning: 'Call' is deprecated [-Wdeprecated-declarations]
  callback->Call(2, argv);
            ^
../node_modules/nan/nan.h:1741:3: note: 'Call' has been explicitly marked deprecated here
  NAN_DEPRECATED inline v8::Local<v8::Value>
  ^
../node_modules/nan/nan.h:106:40: note: expanded from macro 'NAN_DEPRECATED'
# define NAN_DEPRECATED __attribute__((deprecated))
                                       ^
2 warnings and 10 errors generated.
make: *** [Release/obj.target/scrypt/src/node-boilerplate/scrypt_params_async.o] Error 1
gyp ERR! build error
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack     at ChildProcess.onExit (/usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:194:23)
gyp ERR! stack     at ChildProcess.emit (events.js:314:20)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:276:12)
gyp ERR! System Darwin 19.6.0
gyp ERR! command "/usr/local/Cellar/node/14.5.0/bin/node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /usr/local/lib/node_modules/scrypt
gyp ERR! node -v v14.5.0
gyp ERR! node-gyp -v v5.1.0
gyp ERR! not ok
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! scrypt@6.0.3 install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the scrypt@6.0.3 install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /Users/xyz/.npm/_logs/2020-07-21T10_17_05_706Z-debug.log

the mentioned "complete log" looks like this:

0 info it worked if it ends with ok
1 verbose cli [
1 verbose cli   '/usr/local/Cellar/node/14.5.0/bin/node',
1 verbose cli   '/usr/local/bin/npm',
1 verbose cli   'install',
1 verbose cli   '-g',
1 verbose cli   'scrypt'
1 verbose cli ]
2 info using npm@6.14.5
3 info using node@v14.5.0
4 verbose npm-session f8e98571f4b1970b
5 silly install loadCurrentTree
6 silly install readGlobalPackageData
7 http fetch GET 200 https://registry.npmjs.org/scrypt 204ms
8 http fetch GET 200 https://registry.npmjs.org/scrypt/-/scrypt-6.0.3.tgz 94ms
9 silly pacote tag manifest for scrypt@latest fetched in 316ms
10 timing stage:loadCurrentTree Completed in 331ms
11 silly install loadIdealTree
12 silly install cloneCurrentTreeToIdealTree
13 timing stage:loadIdealTree:cloneCurrentTree Completed in 1ms
14 silly install loadShrinkwrap
15 timing stage:loadIdealTree:loadShrinkwrap Completed in 0ms
16 silly install loadAllDepsIntoIdealTree
17 silly resolveWithNewModule scrypt@6.0.3 checking installable status
18 http fetch GET 200 https://registry.npmjs.org/nan 59ms
19 http fetch GET 200 https://registry.npmjs.org/nan/-/nan-2.14.1.tgz 57ms
20 silly pacote range manifest for nan@^2.0.8 fetched in 122ms
21 silly resolveWithNewModule nan@2.14.1 checking installable status
22 timing stage:loadIdealTree:loadAllDepsIntoIdealTree Completed in 128ms
23 timing stage:loadIdealTree Completed in 130ms
24 silly currentTree lib
25 silly idealTree lib
25 silly idealTree └─┬ scrypt@6.0.3
25 silly idealTree   └── nan@2.14.1
26 silly install generateActionsToTake
27 timing stage:generateActionsToTake Completed in 16ms
28 silly diffTrees action count 2
29 silly diffTrees add nan@2.14.1
30 silly diffTrees add scrypt@6.0.3
31 silly decomposeActions action count 16
32 silly decomposeActions fetch nan@2.14.1
33 silly decomposeActions extract nan@2.14.1
34 silly decomposeActions preinstall nan@2.14.1
35 silly decomposeActions build nan@2.14.1
36 silly decomposeActions install nan@2.14.1
37 silly decomposeActions postinstall nan@2.14.1
38 silly decomposeActions finalize nan@2.14.1
39 silly decomposeActions refresh-package-json nan@2.14.1
40 silly decomposeActions fetch scrypt@6.0.3
41 silly decomposeActions extract scrypt@6.0.3
42 silly decomposeActions preinstall scrypt@6.0.3
43 silly decomposeActions build scrypt@6.0.3
44 silly decomposeActions install scrypt@6.0.3
45 silly decomposeActions postinstall scrypt@6.0.3
46 silly decomposeActions finalize scrypt@6.0.3
47 silly decomposeActions refresh-package-json scrypt@6.0.3
48 silly install executeActions
49 silly doSerial global-install 16
50 verbose correctMkdir /Users/xyz/.npm/_locks correctMkdir not in flight; initializing
51 verbose lock using /Users/xyz/.npm/_locks/staging-3a08f0df5026584d.lock for /usr/local/lib/node_modules/.staging
52 silly doParallel extract 2
53 silly extract nan@2.14.1
54 silly extract scrypt@6.0.3
55 silly tarball trying scrypt@latest by hash: sha1-BOAUpWgrU/pQwtXM4WfXGcBthw0=
56 silly tarball trying nan@^2.0.8 by hash: sha512-isWHgVjnFjh2x2yuJ/tj3JbwoHu3UC2dX5G/88Cm24yB6YopVgxvBObDY7n5xW6ExmFhJpSEQqFPvq9zaXc8Jw==
57 silly extract nan@^2.0.8 extracted to /usr/local/lib/node_modules/.staging/nan-7d749488 (47ms)
58 silly extract scrypt@latest extracted to /usr/local/lib/node_modules/.staging/scrypt-71ea5a1b (73ms)
59 timing action:extract Completed in 76ms
60 silly doReverseSerial unbuild 16
61 silly doSerial remove 16
62 silly doSerial move 16
63 silly doSerial finalize 16
64 silly finalize /usr/local/lib/node_modules/scrypt/node_modules/nan
65 silly finalize /usr/local/lib/node_modules/scrypt
66 timing action:finalize Completed in 9ms
67 silly doParallel refresh-package-json 2
68 silly refresh-package-json /usr/local/lib/node_modules/scrypt/node_modules/nan
69 silly refresh-package-json /usr/local/lib/node_modules/scrypt
70 timing action:refresh-package-json Completed in 16ms
71 silly doParallel preinstall 2
72 silly preinstall nan@2.14.1
73 info lifecycle nan@2.14.1~preinstall: nan@2.14.1
74 silly preinstall scrypt@6.0.3
75 info lifecycle scrypt@6.0.3~preinstall: scrypt@6.0.3
76 verbose lifecycle scrypt@6.0.3~preinstall: unsafe-perm in lifecycle true
77 verbose lifecycle scrypt@6.0.3~preinstall: PATH: /usr/local/lib/node_modules/npm/node_modules/npm-lifecycle/node-gyp-bin:/usr/local/lib/node_modules/scrypt/node_modules/.bin:/usr/local/lib/node_modules/.bin:/usr/local/sbin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/Library/TeX/texbin:/opt/X11/bin:/Library/Apple/usr/bin
78 verbose lifecycle scrypt@6.0.3~preinstall: CWD: /usr/local/lib/node_modules/scrypt
79 silly lifecycle scrypt@6.0.3~preinstall: Args: [ '-c', 'node node-scrypt-preinstall.js' ]
80 silly lifecycle scrypt@6.0.3~preinstall: Returned: code: 0  signal: null
81 timing action:preinstall Completed in 4346ms
82 silly doSerial build 16
83 silly build nan@2.14.1
84 info linkStuff nan@2.14.1
85 silly linkStuff nan@2.14.1 has /usr/local/lib/node_modules/scrypt/node_modules as its parent node_modules
86 silly linkStuff nan@2.14.1 is part of a global install
87 silly linkStuff nan@2.14.1 is installed into a global node_modules
88 silly build scrypt@6.0.3
89 info linkStuff scrypt@6.0.3
90 silly linkStuff scrypt@6.0.3 has /usr/local/lib/node_modules as its parent node_modules
91 silly linkStuff scrypt@6.0.3 is part of a global install
92 silly linkStuff scrypt@6.0.3 is installed into a global node_modules
93 silly linkStuff scrypt@6.0.3 is installed into the top-level global node_modules
94 timing action:build Completed in 1ms
95 silly doSerial global-link 16
96 silly doParallel update-linked 0
97 silly doSerial install 16
98 silly install nan@2.14.1
99 info lifecycle nan@2.14.1~install: nan@2.14.1
100 silly install scrypt@6.0.3
101 info lifecycle scrypt@6.0.3~install: scrypt@6.0.3
102 verbose lifecycle scrypt@6.0.3~install: unsafe-perm in lifecycle true
103 verbose lifecycle scrypt@6.0.3~install: PATH: /usr/local/lib/node_modules/npm/node_modules/npm-lifecycle/node-gyp-bin:/usr/local/lib/node_modules/scrypt/node_modules/.bin:/usr/local/lib/node_modules/.bin:/usr/local/sbin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/Library/TeX/texbin:/opt/X11/bin:/Library/Apple/usr/bin
104 verbose lifecycle scrypt@6.0.3~install: CWD: /usr/local/lib/node_modules/scrypt
105 silly lifecycle scrypt@6.0.3~install: Args: [ '-c', 'node-gyp rebuild' ]
106 silly lifecycle scrypt@6.0.3~install: Returned: code: 1  signal: null
107 info lifecycle scrypt@6.0.3~install: Failed to exec install script
108 timing action:install Completed in 4464ms
109 verbose unlock done using /Users/xyz/.npm/_locks/staging-3a08f0df5026584d.lock for /usr/local/lib/node_modules/.staging
110 timing stage:rollbackFailedOptional Completed in 42ms
111 timing stage:runTopLevelLifecycles Completed in 9439ms
112 verbose stack Error: scrypt@6.0.3 install: `node-gyp rebuild`
112 verbose stack Exit status 1
112 verbose stack     at EventEmitter.<anonymous> (/usr/local/lib/node_modules/npm/node_modules/npm-lifecycle/index.js:332:16)
112 verbose stack     at EventEmitter.emit (events.js:314:20)
112 verbose stack     at ChildProcess.<anonymous> (/usr/local/lib/node_modules/npm/node_modules/npm-lifecycle/lib/spawn.js:55:14)
112 verbose stack     at ChildProcess.emit (events.js:314:20)
112 verbose stack     at maybeClose (internal/child_process.js:1051:16)
112 verbose stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:287:5)
113 verbose pkgid scrypt@6.0.3
114 verbose cwd /Users/xyz
115 verbose Darwin 19.6.0
116 verbose argv "/usr/local/Cellar/node/14.5.0/bin/node" "/usr/local/bin/npm" "install" "-g" "scrypt"
117 verbose node v14.5.0
118 verbose npm  v6.14.5
119 error code ELIFECYCLE
120 error errno 1
121 error scrypt@6.0.3 install: `node-gyp rebuild`
121 error Exit status 1
122 error Failed at the scrypt@6.0.3 install script.
122 error This is probably not a problem with npm. There is likely additional logging output above.
123 verbose exit [ 1, true

Now, I went and read about this in stack overflow and similar sites and thought it might be an issue due to missing permissions. Still, setting the entire node-folder in /usr/local/lib/node-modules to chmod 777 doesnt do anything - and running node using sudo simply fails.

I also completely removed everything (node etc) and reinstalled from scratch (via brew) - same problem...

Anyone has an idea how to solve this issue?

Xenonite
  • 1,823
  • 4
  • 26
  • 39

3 Answers3

1

Installing the module from source works, yet that doesnt solve the problem. I'll explain why:

This will clone the scrypt repo and build the package without errors:

git clone https://github.com/barrysteyn/node-scrypt.git
cd node-scrypt
npm install
node-gyp configure build

Following this thread How to install a node.js module without using npm?, I was able to install the node module from that repo without errors using

node install .

(in the dir or the repo)

Still, the dependencies of the scrypt in my other scripts (e.g. react) trigger a re-installation with a rebuild/compilation that lead to the exact same errors posted above.

Xenonite
  • 1,823
  • 4
  • 26
  • 39
0

From the look of the Github issues for the scrypt package, the package is deprecated, and does not support Node versions newer than 10. You appear to be trying to install on Node 14.

https://github.com/barrysteyn/node-scrypt/issues/192

Dave Irvine
  • 384
  • 4
  • 14
  • that is correct. it is a dependency of another package (specifically gamache-cli). so to install ganach-cli, i need to install scrypt. at least the installation of scrypt is triggered automatically when i try to run "npm install -g ganache-cli". so how do i install scrypt in a way in my current setup that allows me to install ganache-cli? – Xenonite Aug 17 '20 at 14:13
  • In your current setup I don't believe it's possible. You would need to downgrade to Node 10. – Dave Irvine Aug 19 '20 at 10:07
0

There is already fix in master branch, however new version was not released yet. You can try to use fixed version from git:

npm install github:barrysteyn/node-scrypt#fb60a8d3c158fe115a624b5ffa7480f3a24b03fb

However, if this is your direct dependecy, consider following warning in README:

#WARNING!!! This module is deprecated. Instead, use https://nodejs.org/api/crypto.html#crypto_crypto_scrypt_password_salt_keylen_options_callback

We are waiting for the new version release from May 2020 in vain: https://github.com/barrysteyn/node-scrypt/pull/197#issuecomment-630954048

Honza
  • 974
  • 10
  • 18