Hyperledger composer-cli install failing Mac OS - hyperledger-composer

Following a Hyperledger Dev course https://hyperledger.github.io/composer/latest/installing/development-tools.html
And ran the npm install -g composer-cli command on Mac OS. It doesn't seem like a permissions problem, I've had those before. This is the line that stands out to me from the log below;
Failed at the grpc#1.10.1 install script.
I am running NPM version 6.7.0 and Node version 11.10.0
18655 silly install grpc#1.10.1
18656 info lifecycle grpc#1.10.1~install: grpc#1.10.1
18657 verbose lifecycle grpc#1.10.1~install: unsafe-perm in lifecycle true
18658 verbose lifecycle grpc#1.10.1~install: PATH: /usr/local/lib/node_modules/npm/node_modules/npm-lifecycle/node-gyp-bin:/usr/local/lib/node_modules/composer-cli/node_modules/grpc/node_modules/.bin:/usr/local/lib/node_modules/composer-cli/node_modules/.bin:/usr/local/lib/node_modules/.bin:/Applications/Postgres.app/Contents/Versions/latest/bin:/usr/local:/usr/local/bin:/usr/local/sbin:/usr/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/share/dotnet:/Library/Frameworks/Mono.framework/Versions/Current/Commands
18659 verbose lifecycle grpc#1.10.1~install: CWD: /usr/local/lib/node_modules/composer-cli/node_modules/grpc
18660 silly lifecycle grpc#1.10.1~install: Args: [ '-c',
18660 silly lifecycle 'node-pre-gyp install --fallback-to-build --library=static_library' ]
18661 silly lifecycle grpc#1.10.1~install: Returned: code: 1 signal: null
18662 info lifecycle grpc#1.10.1~install: Failed to exec install script
18663 timing action:install Completed in 40426ms
18664 verbose unlock done using /Users/mu/.npm/_locks/staging-3a08f0df5026584d.lock for /usr/local/lib/node_modules/.staging
18665 timing stage:rollbackFailedOptional Completed in 1847ms
18666 timing stage:runTopLevelLifecycles Completed in 62690ms
18667 verbose stack Error: grpc#1.10.1 install:node-pre-gyp install --fallback-to-build --library=static_library
18667 verbose stack Exit status 1
18667 verbose stack at EventEmitter.<anonymous> (/usr/local/lib/node_modules/npm/node_modules/npm-lifecycle/index.js:301:16)
18667 verbose stack at EventEmitter.emit (events.js:197:13)
18667 verbose stack at ChildProcess.<anonymous> (/usr/local/lib/node_modules/npm/node_modules/npm-lifecycle/lib/spawn.js:55:14)
18667 verbose stack at ChildProcess.emit (events.js:197:13)
18667 verbose stack at maybeClose (internal/child_process.js:984:16)
18667 verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js:265:5)
18668 verbose pkgid grpc#1.10.1
18669 verbose cwd /Users/mu/Documents/Hyperledger
18670 verbose Darwin 18.2.0
18671 verbose argv "/usr/local/Cellar/node/11.10.0/bin/node" "/usr/local/bin/npm" "install" "-g" "composer-cli"
18672 verbose node v11.10.0
18673 verbose npm v6.7.0
18674 error code ELIFECYCLE
18675 error errno 1
18676 error grpc#1.10.1 install:node-pre-gyp install --fallback-to-build --library=static_library
18676 error Exit status 1
18677 error Failed at the grpc#1.10.1 install script.
18677 error This is probably not a problem with npm. There is likely additional logging output above.
18678 verbose exit [ 1, true ]

You need to use node version 8.9 or higher but 9 or higher than that arenot supported and npm 5.x. It is clearly specified in pre-requisities section

Related

Npm run watch doesn't work with laravel : sh: cross-env: command not found

I want to execute "npm run watch" in my laravel project but it doesn't work.
There is the error message
# watch /Applications/MAMP/htdocs/test-tech/laravel5
npm run development -- --watch
# development /Applications/MAMP/htdocs/test-tech/laravel5
cross-env NODE_ENV=development node_modules/webpack/bin/webpack.js --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js "--watch"
sh: cross-env: command not found
npm ERR! file sh
npm ERR! code ELIFECYCLE
npm ERR! errno ENOENT
npm ERR! syscall spawn
npm ERR! # development: cross-env NODE_ENV=development node_modules/webpack/bin/webpack.js --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js "--watch"
npm ERR! spawn ENOENT
npm ERR!
npm ERR! Failed at the # development script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm WARN Local package.json exists, but node_modules missing, did you mean to install?
npm ERR! A complete log of this run can be found in:
npm ERR! /Users/xxx/.npm/_logs/2019-03-29T11_19_55_390Z-debug.log
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! # watch: npm run development -- --watch
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the # watch script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm WARN Local package.json exists, but node_modules missing, did you mean to install?
npm ERR! A complete log of this run can be found in:
npm ERR! /Users/xxx/.npm/_logs/2019-03-29T11_19_55_422Z-debug.log
And the debug file
0 info it worked if it ends with ok
1 verbose cli [ '/usr/local/bin/node', '/usr/local/bin/npm', 'run', 'watch' ]
2 info using npm#5.6.0
3 info using node#v8.11.3
4 verbose run-script [ 'prewatch', 'watch', 'postwatch' ]
5 info lifecycle #~prewatch: #
6 info lifecycle #~watch: #
7 verbose lifecycle #~watch: unsafe-perm in lifecycle true
8 verbose lifecycle #~watch: PATH: /usr/local/lib/node_modules/npm/node_modules/npm-lifecycle/node-gyp-bin:/Applications/MAMP/htdocs/test-tech/laravel5/node_modules/.bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin
9 verbose lifecycle #~watch: CWD: /Applications/MAMP/htdocs/test-tech/laravel5
10 silly lifecycle #~watch: Args: [ '-c', 'npm run development -- --watch' ]
11 silly lifecycle #~watch: Returned: code: 1 signal: null
12 info lifecycle #~watch: Failed to exec watch script
13 verbose stack Error: # watch: `npm run development -- --watch`
13 verbose stack Exit status 1
13 verbose stack at EventEmitter.<anonymous> (/usr/local/lib/node_modules/npm/node_modules/npm-lifecycle/index.js:285:16)
13 verbose stack at emitTwo (events.js:126:13)
13 verbose stack at EventEmitter.emit (events.js:214:7)
13 verbose stack at ChildProcess.<anonymous> (/usr/local/lib/node_modules/npm/node_modules/npm-lifecycle/lib/spawn.js:55:14)
13 verbose stack at emitTwo (events.js:126:13)
13 verbose stack at ChildProcess.emit (events.js:214:7)
13 verbose stack at maybeClose (internal/child_process.js:925:16)
13 verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js:209:5)
14 verbose pkgid #
15 verbose cwd /Applications/MAMP/htdocs/test-tech/laravel5
16 verbose Darwin 18.2.0
17 verbose argv "/usr/local/bin/node" "/usr/local/bin/npm" "run" "watch"
18 verbose node v8.11.3
19 verbose npm v5.6.0
20 error code ELIFECYCLE
21 error errno 1
22 error # watch: `npm run development -- --watch`
22 error Exit status 1
23 error Failed at the # watch script.
23 error This is probably not a problem with npm. There is likely additional logging output above.
24 verbose exit [ 1, true ]
I googled it and tried some solutions but it still doesn't work.
How to resolve it ?
Thanks
The problem is that you are missing cross-env, you can run
npm install -g cross-env to install it globally, or npm install cross-env to install it locally in the current project.

Laravel - npm run watch does not work on Lara 7, Node: v10.15.0 and NPM: v6.5.0

I have an issue with Laravel and Vue. When I try to compile everything with npm run watch I get these (it suddenly stopped working):
Additional dependencies must be installed. This will only take a moment.
Running: yarn add vue-template-compiler --dev --production=false
/bin/sh: yarn: command not found
/Applications/MAMP_2018-03-15_05-39-43/htdocs/sandbox/lvue/node_modules/webpack-cli/bin/cli.js:244
throw err;
^
Error: Command failed: yarn add vue-template-compiler --dev --production=false
/bin/sh: yarn: command not found
at checkExecSyncError (child_process.js:616:11)
at Object.execSync (child_process.js:653:13)
at Dependencies.execute (/Applications/MAMP_2018-03-15_05-39-43/htdocs/sandbox/lvue/node_modules/laravel-mix/src/Dependencies.js:52:22)
at dependencies.reject.tap.dependencies (/Applications/MAMP_2018-03-15_05-39-43/htdocs/sandbox/lvue/node_modules/laravel-mix/src/Dependencies.js:30:22)
at Array.value (/Applications/MAMP_2018-03-15_05-39-43/htdocs/sandbox/lvue/node_modules/laravel-mix/src/helpers.js:24:13)
at Dependencies.install (/Applications/MAMP_2018-03-15_05-39-43/htdocs/sandbox/lvue/node_modules/laravel-mix/src/Dependencies.js:29:14)
at Function.dependencies (/Applications/MAMP_2018-03-15_05-39-43/htdocs/sandbox/lvue/node_modules/laravel-mix/src/Assert.js:77:40)
at concat.filter.tap.dependencies (/Applications/MAMP_2018-03-15_05-39-43/htdocs/sandbox/lvue/node_modules/laravel-mix/src/components/ComponentFactory.js:130:24)
at Array.value (/Applications/MAMP_2018-03-15_05-39-43/htdocs/sandbox/lvue/node_modules/laravel-mix/src/helpers.js:24:13)
at ComponentFactory.installDependencies (/Applications/MAMP_2018-03-15_05-39-43/htdocs/sandbox/lvue/node_modules/laravel-mix/src/components/ComponentFactory.js:129:14)
at Mix.listen (/Applications/MAMP_2018-03-15_05-39-43/htdocs/sandbox/lvue/node_modules/laravel-mix/src/components/ComponentFactory.js:54:44)
at events.(anonymous function).forEach.handler (/Applications/MAMP_2018-03-15_05-39-43/htdocs/sandbox/lvue/node_modules/laravel-mix/src/Dispatcher.js:34:47)
at Array.forEach (<anonymous>)
at Dispatcher.fire (/Applications/MAMP_2018-03-15_05-39-43/htdocs/sandbox/lvue/node_modules/laravel-mix/src/Dispatcher.js:34:28)
at Mix.dispatch (/Applications/MAMP_2018-03-15_05-39-43/htdocs/sandbox/lvue/node_modules/laravel-mix/src/Mix.js:119:25)
at Object.<anonymous> (/Applications/MAMP_2018-03-15_05-39-43/htdocs/sandbox/lvue/node_modules/laravel-mix/setup/webpack.config.js:19:5)
at Module._compile (/Applications/MAMP_2018-03-15_05-39-43/htdocs/sandbox/lvue/node_modules/v8-compile-cache/v8-compile-cache.js:178:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:700:10)
at Module.load (internal/modules/cjs/loader.js:599:32)
at tryModuleLoad (internal/modules/cjs/loader.js:538:12)
at Function.Module._load (internal/modules/cjs/loader.js:530:3)
at Module.require (internal/modules/cjs/loader.js:637:17)
at require (/Applications/MAMP_2018-03-15_05-39-43/htdocs/sandbox/lvue/node_modules/v8-compile-cache/v8-compile-cache.js:159:20)
at WEBPACK_OPTIONS (/Applications/MAMP_2018-03-15_05-39-43/htdocs/sandbox/lvue/node_modules/webpack-cli/bin/convert-argv.js:133:13)
at requireConfig (/Applications/MAMP_2018-03-15_05-39-43/htdocs/sandbox/lvue/node_modules/webpack-cli/bin/convert-argv.js:135:6)
at /Applications/MAMP_2018-03-15_05-39-43/htdocs/sandbox/lvue/node_modules/webpack-cli/bin/convert-argv.js:142:17
at Array.forEach (<anonymous>)
at module.exports (/Applications/MAMP_2018-03-15_05-39-43/htdocs/sandbox/lvue/node_modules/webpack-cli/bin/convert-argv.js:140:15)
at yargs.parse (/Applications/MAMP_2018-03-15_05-39-43/htdocs/sandbox/lvue/node_modules/webpack-cli/bin/cli.js:241:39)
at Object.parse (/Applications/MAMP_2018-03-15_05-39-43/htdocs/sandbox/lvue/node_modules/yargs/yargs.js:567:18)
at /Applications/MAMP_2018-03-15_05-39-43/htdocs/sandbox/lvue/node_modules/webpack-cli/bin/cli.js:219:8
at Object.<anonymous> (/Applications/MAMP_2018-03-15_05-39-43/htdocs/sandbox/lvue/node_modules/webpack-cli/bin/cli.js:538:3)
at Module._compile (internal/modules/cjs/loader.js:689:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:700:10)
at Module.load (internal/modules/cjs/loader.js:599:32)
at tryModuleLoad (internal/modules/cjs/loader.js:538:12)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! # development: `cross-env NODE_ENV=development node_modules/webpack/bin/webpack.js --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js "--watch"`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the # development 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/kosingas/.npm/_logs/2018-12-31T13_48_22_168Z-debug.log
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! # watch: `npm run development -- --watch`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the # watch 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/kosingas/.npm/_logs/2018-12-31T13_48_22_209Z-debug.log
Borivojes-MacBook-Pro:lvue kosingas$
I am not sure what to do. Have been googling for quote some time, downgraded Node from 11 to stable LTS version 10 and nothing.
Click here to see the screenshot of the errors that I'm getting
This is what I see when I open the error log file:
0 info it worked if it ends with ok
1 verbose cli [ '/usr/local/bin/node', '/usr/local/bin/npm', 'run', 'watch' ]
2 info using npm#6.5.0
3 info using node#v10.15.0
4 verbose run-script [ 'prewatch', 'watch', 'postwatch' ]
5 info lifecycle #~prewatch: #
6 info lifecycle #~watch: #
7 verbose lifecycle #~watch: unsafe-perm in lifecycle true
8 verbose lifecycle #~watch: PATH: /usr/local/lib/node_modules/npm/node_modules/npm-lifecycle/node-gyp-bin:/Applications/MAMP_2018-03-15_05-39$
9 verbose lifecycle #~watch: CWD: /Applications/MAMP_2018-03-15_05-39-43/htdocs/sandbox/lvue
10 silly lifecycle #~watch: Args: [ '-c', 'npm run development -- --watch' ]
11 silly lifecycle #~watch: Returned: code: 1 signal: null
12 info lifecycle #~watch: Failed to exec watch script
13 verbose stack Error: # watch: `npm run development -- --watch`
13 verbose stack Exit status 1
13 verbose stack at EventEmitter.<anonymous> (/usr/local/lib/node_modules/npm/node_modules/npm-lifecycle/index.js:301:16)
13 verbose stack at EventEmitter.emit (events.js:182:13)
13 verbose stack at ChildProcess.<anonymous> (/usr/local/lib/node_modules/npm/node_modules/npm-lifecycle/lib/spawn.js:55:14)
13 verbose stack at ChildProcess.emit (events.js:182:13)
13 verbose stack at maybeClose (internal/child_process.js:962:16)
13 verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js:251:5)
14 verbose pkgid #
15 verbose cwd /Applications/MAMP_2018-03-15_05-39-43/htdocs/sandbox/lvue
16 verbose Darwin 18.0.0
17 verbose argv "/usr/local/bin/node" "/usr/local/bin/npm" "run" "watch"
18 verbose node v10.15.0
'vue-template-compiler' is missing on your packag.json, do :
rm -R node_modules
npm install
npm install -g yarnpkg
npm install --save vue-template-compiler
npm run dev

installing Terminalizer using npm on OSX

I am trying to install terminalizer on OSX using npm but I get error with and without using sudo. Not sure how I can proceed with fixing it and installing it successfully:
$ npm install -g terminalizer
npm WARN checkPermissions Missing write access to /usr/local/lib/node_modules
npm ERR! path /usr/local/lib/node_modules
npm ERR! code EACCES
npm ERR! errno -13
npm ERR! syscall access
npm ERR! Error: EACCES: permission denied, access '/usr/local/lib/node_modules'
npm ERR! { [Error: EACCES: permission denied, access '/usr/local/lib/node_modules']
npm ERR! stack:
npm ERR! 'Error: EACCES: permission denied, access \'/usr/local/lib/node_modules\'',
npm ERR! errno: -13,
npm ERR! code: 'EACCES',
npm ERR! syscall: 'access',
npm ERR! path: '/usr/local/lib/node_modules' }
npm ERR!
npm ERR! The operation was rejected by your operating system.
npm ERR! It is likely you do not have the permissions to access this file as the current user
npm ERR!
npm ERR! If you believe this might be a permissions issue, please double-check the
npm ERR! permissions of the file and its containing directories, or try running
npm ERR! the command again as root/Administrator (though this is not recommended).
npm ERR! A complete log of this run can be found in:
npm ERR! /Users/mona/.npm/_logs/2018-12-22T21_48_44_353Z-debug.log
Monas-MacBook-Pro:NotebooksforMLReview mona$ sudo npm install -g terminalizer
Password:
/usr/local/bin/terminalizer -> /usr/local/lib/node_modules/terminalizer/bin/app.js
> node-pty-prebuilt#0.7.6 install /usr/local/lib/node_modules/terminalizer/node_modules/node-pty-prebuilt
> prebuild-install || node scripts/install.js
prebuild-install WARN install EACCES: permission denied, access '/Users/mona/.npm'
gyp ERR! configure error
gyp ERR! stack Error: Command failed: /Users/mona/anaconda3/bin/python -c import sys; print "%s.%s.%s" % sys.version_info[:3];
gyp ERR! stack File "<string>", line 1
gyp ERR! stack import sys; print "%s.%s.%s" % sys.version_info[:3];
gyp ERR! stack ^
gyp ERR! stack SyntaxError: invalid syntax
gyp ERR! stack
gyp ERR! stack at ChildProcess.exithandler (child_process.js:294:12)
gyp ERR! stack at ChildProcess.emit (events.js:182:13)
gyp ERR! stack at maybeClose (internal/child_process.js:962:16)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:251:5)
gyp ERR! System Darwin 17.7.0
gyp ERR! command "/usr/local/bin/node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild" "--build_v8_with_gn=false"
gyp ERR! cwd /usr/local/lib/node_modules/terminalizer/node_modules/node-pty-prebuilt
gyp ERR! node -v v10.14.2
gyp ERR! node-gyp -v v3.8.0
gyp ERR! not ok
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! node-pty-prebuilt#0.7.6 install: `prebuild-install || node scripts/install.js`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the node-pty-prebuilt#0.7.6 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/mona/.npm/_logs/2018-12-22T21_49_13_893Z-debug.log
Monas-MacBook-Pro:NotebooksforMLReview mona$ vi /Users/mona/.npm/_logs/2018-12-22T21_49_13_893Z-debug.log
I have the following:
$ uname -a
Darwin Monas-MacBook-Pro.local 17.7.0 Darwin Kernel Version 17.7.0: Thu Jun 21 22:59:54 PDT 2018; root:xnu-4570.71.2~2/RELEASE_X86_64 x86_64
$ npm -v
6.4.1
and the last 100 lines of the log:
$ tail -100 /Users/mona/.npm/_logs/2018-12-22T21_49_13_893Z-debug.log
6955 info lifecycle tar-stream#1.6.2~install: tar-stream#1.6.2
6956 silly install inflight#1.0.6
6957 info lifecycle inflight#1.0.6~install: inflight#1.0.6
6958 silly install glob#7.1.3
6959 info lifecycle glob#7.1.3~install: glob#7.1.3
6960 silly install rimraf#2.6.2
6961 info lifecycle rimraf#2.6.2~install: rimraf#2.6.2
6962 silly install fs-extra#0.30.0
6963 info lifecycle fs-extra#0.30.0~install: fs-extra#0.30.0
6964 silly install pump#2.0.1
6965 info lifecycle pump#2.0.1~install: pump#2.0.1
6966 silly install simple-get#2.8.1
6967 info lifecycle simple-get#2.8.1~install: simple-get#2.8.1
6968 silly install pump#1.0.3
6969 info lifecycle pump#1.0.3~install: pump#1.0.3
6970 silly install tar-fs#1.16.3
6971 info lifecycle tar-fs#1.16.3~install: tar-fs#1.16.3
6972 silly install prebuild-install#5.2.2
6973 info lifecycle prebuild-install#5.2.2~install: prebuild-install#5.2.2
6974 silly install xtend#2.1.2
6975 info lifecycle xtend#2.1.2~install: xtend#2.1.2
6976 silly install through2#0.2.3
6977 info lifecycle through2#0.2.3~install: through2#0.2.3
6978 silly install progress-stream#1.2.0
6979 info lifecycle progress-stream#1.2.0~install: progress-stream#1.2.0
6980 silly install nugget#2.0.1
6981 info lifecycle nugget#2.0.1~install: nugget#2.0.1
6982 silly install electron-download#3.3.0
6983 info lifecycle electron-download#3.3.0~install: electron-download#3.3.0
6984 silly install y18n#4.0.0
6985 info lifecycle y18n#4.0.0~install: y18n#4.0.0
6986 silly install camelcase#5.0.0
6987 info lifecycle camelcase#5.0.0~install: camelcase#5.0.0
6988 silly install yargs-parser#11.1.1
6989 info lifecycle yargs-parser#11.1.1~install: yargs-parser#11.1.1
6990 silly install ansi-regex#3.0.0
6991 info lifecycle ansi-regex#3.0.0~install: ansi-regex#3.0.0
6992 silly install find-up#3.0.0
6993 info lifecycle find-up#3.0.0~install: find-up#3.0.0
6994 silly install is-fullwidth-code-point#2.0.0
6995 info lifecycle is-fullwidth-code-point#2.0.0~install: is-fullwidth-code-point#2.0.0
6996 silly install strip-ansi#4.0.0
6997 info lifecycle strip-ansi#4.0.0~install: strip-ansi#4.0.0
6998 silly install string-width#2.1.1
6999 info lifecycle string-width#2.1.1~install: string-width#2.1.1
7000 silly install yauzl#2.4.1
7001 info lifecycle yauzl#2.4.1~install: yauzl#2.4.1
7002 silly install extract-zip#1.6.7
7003 info lifecycle extract-zip#1.6.7~install: extract-zip#1.6.7
7004 silly install async-promises#0.2.1
7005 info lifecycle async-promises#0.2.1~install: async-promises#0.2.1
7006 silly install death#1.1.0
7007 info lifecycle death#1.1.0~install: death#1.1.0
7008 silly install deepmerge#2.2.1
7009 info lifecycle deepmerge#2.2.1~install: deepmerge#2.2.1
7010 silly install electron#2.0.16
7011 info lifecycle electron#2.0.16~install: electron#2.0.16
7012 silly install flowa#4.0.2
7013 info lifecycle flowa#4.0.2~install: flowa#4.0.2
7014 silly install fs-extra#5.0.0
7015 info lifecycle fs-extra#5.0.0~install: fs-extra#5.0.0
7016 silly install gif-encoder#0.6.1
7017 info lifecycle gif-encoder#0.6.1~install: gif-encoder#0.6.1
7018 silly install inquirer#6.2.1
7019 info lifecycle inquirer#6.2.1~install: inquirer#6.2.1
7020 silly install js-yaml#3.12.0
7021 info lifecycle js-yaml#3.12.0~install: js-yaml#3.12.0
7022 silly install node-pty-prebuilt#0.7.6
7023 info lifecycle node-pty-prebuilt#0.7.6~install: node-pty-prebuilt#0.7.6
7024 verbose lifecycle node-pty-prebuilt#0.7.6~install: unsafe-perm in lifecycle false
7025 verbose lifecycle node-pty-prebuilt#0.7.6~install: PATH: /usr/local/lib/node_modules/npm/node_modules/npm-lifecycle/node-gyp-bin:/usr/local/lib/node_modules/terminalizer/node_modules/node-pty-prebuilt/node_modules/.bin:/usr/local/lib/node_modules/terminalizer/node_modules/.bin:/usr/local/lib/node_modules/.bin:/Users/mona/anaconda3/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/opt/X11/bin:/Library/Frameworks/Mono.framework/Versions/Current/Commands
7026 verbose lifecycle node-pty-prebuilt#0.7.6~install: CWD: /usr/local/lib/node_modules/terminalizer/node_modules/node-pty-prebuilt
7027 silly lifecycle node-pty-prebuilt#0.7.6~install: Args: [ '-c', 'prebuild-install || node scripts/install.js' ]
7028 silly lifecycle node-pty-prebuilt#0.7.6~install: Returned: code: 1 signal: null
7029 info lifecycle node-pty-prebuilt#0.7.6~install: Failed to exec install script
7030 timing action:install Completed in 627ms
7031 verbose unlock done using /Users/mona/.npm/_locks/staging-3a08f0df5026584d.lock for /usr/local/lib/node_modules/.staging
7032 timing stage:rollbackFailedOptional Completed in 922ms
7033 timing stage:runTopLevelLifecycles Completed in 11566ms
7034 verbose stack Error: node-pty-prebuilt#0.7.6 install: `prebuild-install || node scripts/install.js`
7034 verbose stack Exit status 1
7034 verbose stack at EventEmitter.<anonymous> (/usr/local/lib/node_modules/npm/node_modules/npm-lifecycle/index.js:301:16)
7034 verbose stack at EventEmitter.emit (events.js:182:13)
7034 verbose stack at ChildProcess.<anonymous> (/usr/local/lib/node_modules/npm/node_modules/npm-lifecycle/lib/spawn.js:55:14)
7034 verbose stack at ChildProcess.emit (events.js:182:13)
7034 verbose stack at maybeClose (internal/child_process.js:962:16)
7034 verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js:251:5)
7035 verbose pkgid node-pty-prebuilt#0.7.6
7036 verbose cwd /Users/mona/machine learning/NotebooksforMLReview
7037 verbose Darwin 17.7.0
7038 verbose argv "/usr/local/bin/node" "/usr/local/bin/npm" "install" "-g" "terminalizer"
7039 verbose node v10.14.2
7040 verbose npm v6.4.1
7041 error code ELIFECYCLE
7042 error errno 1
7043 error node-pty-prebuilt#0.7.6 install: `prebuild-install || node scripts/install.js`
7043 error Exit status 1
7044 error Failed at the node-pty-prebuilt#0.7.6 install script.
7044 error This is probably not a problem with npm. There is likely additional logging output above.
7045 verbose exit [ 1, true ]
The following installed the Terminalizer (adding the --unsafe-perm flag) (please pitch in if there's a better solution. I am no expert in npm):
$ sudo npm install --unsafe-perm -g terminalizer
Password:
/usr/local/bin/terminalizer -> /usr/local/lib/node_modules/terminalizer/bin/app.js
> node-pty-prebuilt#0.7.6 install /usr/local/lib/node_modules/terminalizer/node_modules/node-pty-prebuilt
> prebuild-install || node scripts/install.js
> electron#2.0.16 postinstall /usr/local/lib/node_modules/terminalizer/node_modules/electron
> node install.js
Downloading SHASUMS256.txt
[============================================>] 100.0% of 5.39 kB (5.39 kB/s)
> node-pty-prebuilt#0.7.6 postinstall /usr/local/lib/node_modules/terminalizer/node_modules/node-pty-prebuilt
> node scripts/post-install.js
+ terminalizer#0.6.0
added 292 packages from 214 contributors in 40.879s

npm won't run dev in laravel

I am trying to get my project to work on fresh debian install. npm install works fine, but then npm run dev gives me this:
15% building modules 45/46 modules 1 active .../www/html/pms/resources/sass/app.scssnpm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! # development: `cross-env NODE_ENV=development node_modules/webpack/bin/webpack.js --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the # development 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! /root/.npm/_logs/2018-12-13T14_03_05_708Z-debug.log
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! # dev: `npm run development`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the # dev 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! /root/.npm/_logs/2018-12-13T14_03_05_720Z-debug.log
and the log that this is pointing to looks like this:
0 info it worked if it ends with ok
1 verbose cli [ '/usr/bin/node', '/usr/bin/npm', 'run', 'dev' ]
2 info using npm#5.8.0
3 info using node#v8.11.2
4 verbose run-script [ 'predev', 'dev', 'postdev' ]
5 info lifecycle #~predev: #
6 info lifecycle #~dev: #
7 verbose lifecycle #~dev: unsafe-perm in lifecycle true
8 verbose lifecycle #~dev: PATH: /usr/share/npm/node_modules/npm-lifecycle/node-gyp-bin:/var/www/html/pms/node_modules/.bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
9 verbose lifecycle #~dev: CWD: /var/www/html/pms
10 silly lifecycle #~dev: Args: [ '-c', 'npm run development' ]
11 silly lifecycle #~dev: Returned: code: 1 signal: null
12 info lifecycle #~dev: Failed to exec dev script
13 verbose stack Error: # dev: `npm run development`
13 verbose stack Exit status 1
13 verbose stack at EventEmitter.<anonymous> (/usr/share/npm/node_modules/npm-lifecycle/index.js:283:16)
13 verbose stack at emitTwo (events.js:126:13)
13 verbose stack at EventEmitter.emit (events.js:214:7)
13 verbose stack at ChildProcess.<anonymous> (/usr/share/npm/node_modules/npm-lifecycle/lib/spawn.js:55:14)
13 verbose stack at emitTwo (events.js:126:13)
13 verbose stack at ChildProcess.emit (events.js:214:7)
13 verbose stack at maybeClose (internal/child_process.js:925:16)
13 verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js:209:5)
14 verbose pkgid #
15 verbose cwd /var/www/html/pms
16 verbose Linux 4.18.0-3-amd64
17 verbose argv "/usr/bin/node" "/usr/bin/npm" "run" "dev"
18 verbose node v8.11.2
19 verbose npm v5.8.0
20 error code ELIFECYCLE
21 error errno 1
22 error # dev: `npm run development`
22 error Exit status 1
23 error Failed at the # dev script.
23 error This is probably not a problem with npm. There is likely additional logging output above.
24 verbose exit [ 1, true ]
I'm not sure what should I do, I google adding some npm modules, reinstalling, deleting cache, but I'm not sure what could be the cause. This works on my Windows Laragon machine. I've installed it on Ubuntu without any problem, but on Debian I cannot make it work. Ideas?
I'm experiencing the same issue with this message before the list of npm ERR that you have posted :
Node Sass could not find a binding for your current environment: OS X
64-bit with Node.js 12.x
Found bindings for the following environments:
- OS X 64-bit with Node.js 7.x
This usually happens because your environment has changed since
running npm install. Run npm rebuild node-sass to download the
binding for your current environment.
As you say that you have installed your project on windows and Ubuntu before to try on your fresh Debian install, you maybe have the same problem.

Failed at the pkcs11js#1.0.13 install script 'node-gyp rebuild'

I am getting following error while trying to install hyperledger composer on my ubuntu:
60822 verbose stack Error: pkcs11js#1.0.13 install: `node-gyp rebuild`
60822 verbose stack Exit status 1
60822 verbose stack at EventEmitter.<anonymous>
(/usr/share/npm/lib/utils/lifecycle.js:232:16)
60822 verbose stack at emitTwo (events.js:87:13)
60822 verbose stack at EventEmitter.emit (events.js:172:7)
60822 verbose stack at ChildProcess.<anonymous>
(/usr/share/npm/lib/utils/spawn.js:24:14)
60822 verbose stack at emitTwo (events.js:87:13)
60822 verbose stack at ChildProcess.emit (events.js:172:7)
60822 verbose stack at maybeClose (internal/child_process.js:821:16)
60822 verbose stack at Process.ChildProcess._handle.onexit
60825 error Linux 4.13.0-37-generic
60826 error argv "/usr/bin/nodejs" "/usr/bin/npm" "install" "-g" "generator-hyperledger-composer"
60827 error node v4.2.6
60828 error npm v3.5.2
60829 error code ELIFECYCLE
60830 error pkcs11js#1.0.13 install: `node-gyp rebuild`
60830 error Exit status 1
Can someone tell me what to do?
I had the same issue when I was trying to install composer-cli. I was running sudo npm install -g composer-cli to install it. So if you're doing the same way (using sudo) try to just run the install command without sudo. This worked for me on Mac.

Resources