Error: spawn cmd ENOENT while starting React APP - node.js

I am creating a React Application. I ran the following command in cmd:
npx create-react-app .
Thereafter I tried to start the server using npm start as instructed in the tutorial:
https://github.com/facebook/create-react-app.
However, I keep getting the following error:
Error: spawn cmd ENOENT.
The log report generated by the error is:
0 info it worked if it ends with ok
1 verbose cli [
1 verbose cli 'C:\\Program Files\\nodejs\\node.exe',
1 verbose cli 'C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js',
1 verbose cli 'start'
1 verbose cli ]
2 info using npm#6.10.2
3 info using node#v12.9.1
4 verbose run-script [ 'prestart', 'start', 'poststart' ]
5 info lifecycle react_todo#0.1.0~prestart: react_todo#0.1.0
6 info lifecycle react_todo#0.1.0~start: react_todo#0.1.0
7 verbose lifecycle react_todo#0.1.0~start: unsafe-perm in lifecycle true
8 verbose lifecycle react_todo#0.1.0~start: PATH: C:\Program Files\nodejs\node_modules\npm\node_modules\npm-lifecycle\node-gyp-bin;E:\Projects\react_todo\node_modules\.bin;C:\Program Files\Java\jdk1.8.0_181\bin;C:\Program Files\nodejs\;C:\ProgramData\chocolatey\bin;E:\Projects\shopping-cart\node_modules\express-generator\bin;C:\Program Files\Git\cmd;C:\Program Files\PuTTY\;C:\Users\Arun\AppData\Local\Programs\Python\Python37-32\Scripts\;C:\Users\Arun\AppData\Local\Programs\Python\Python37-32\;C:\Users\Arun\AppData\Local\Programs\Microsoft VS Code\bin;C:\Program Files (x86)\EasyPHP-Devserver-17\eds-binaries\dbserver\mysql5717x86x191225091928\bin;
9 verbose lifecycle react_todo#0.1.0~start: CWD: E:\Projects\react_todo
10 silly lifecycle react_todo#0.1.0~start: Args: [ '/d /s /c', 'react-scripts start' ]
11 silly lifecycle react_todo#0.1.0~start: Returned: code: 1 signal: null
12 info lifecycle react_todo#0.1.0~start: Failed to exec start script
13 verbose stack Error: react_todo#0.1.0 start: `react-scripts start`
13 verbose stack Exit status 1
13 verbose stack at EventEmitter.<anonymous> (C:\Program Files\nodejs\node_modules\npm\node_modules\npm-lifecycle\index.js:326:16)
13 verbose stack at EventEmitter.emit (events.js:209:13)
13 verbose stack at ChildProcess.<anonymous> (C:\Program Files\nodejs\node_modules\npm\node_modules\npm-lifecycle\lib\spawn.js:55:14)
13 verbose stack at ChildProcess.emit (events.js:209:13)
13 verbose stack at maybeClose (internal/child_process.js:1021:16)
13 verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js:283:5)
14 verbose pkgid react_todo#0.1.0
15 verbose cwd E:\Projects\react_todo
16 verbose Windows_NT 6.1.7600
17 verbose argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "start"
18 verbose node v12.9.1
19 verbose npm v6.10.2
20 error code ELIFECYCLE
21 error errno 1
22 error react_todo#0.1.0 start: `react-scripts start`
22 error Exit status 1
23 error Failed at the react_todo#0.1.0 start script.
23 error This is probably not a problem with npm. There is likely additional logging output above.
24 verbose exit [ 1, true ]
It would be really helpful if could suggest me a way to resolve this issue. Thank You.

I resolved the issue by following these steps if anyone needs it in future:
Goto > Control Panel\System and Security\System\Advance system setting\Enviroment variable and set system variables path C:\Windows\System32\ variable and restart your System.
This comment really helped me out: https://github.com/facebook/create-react-app/issues/6908#issuecomment-495064048.

You should install create-react-app globally with -g.
npm install -g create-react-app
Alternatively, you could skip the installation of create-react-app.
For that you need firstly to update to a newer version of nodejs and npm and then you can run.
npx create-react-app yourappname

Related

Mocha test fails without giving proper error

I have setup mocha to run test on my express application. However mocha test fails every time I run npm test without giving any error refer to the screen
here is my snippet of my package.json, my folder structure and code
I tried running mocha manually also but it doesn't print anything. it just exit the process. lastly i tried running it in the debug mode and here is the log of debug mode
0 info it worked if it ends with ok
1 verbose cli [
1 verbose cli 'C:\\Program Files\\nodejs\\node.exe',
1 verbose cli 'C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js',
1 verbose cli 'run',
1 verbose cli 'test'
1 verbose cli ]
2 info using npm#6.14.10
3 info using node#v14.15.4
4 verbose run-script [ 'pretest', 'test', 'posttest' ]
5 info lifecycle data-central#1.0.0~pretest: data-central#1.0.0
6 info lifecycle data-central#1.0.0~test: data-central#1.0.0
7 verbose lifecycle data-central#1.0.0~test: unsafe-perm in lifecycle true
8 verbose lifecycle data-central#1.0.0~test: PATH: C:\Program Files\nodejs\node_modules\npm\node_modules\npm-lifecycle\node-gyp-bin;E:\The expert Institute\data-central-backend\node_modules\.bin;C:\Program Files\Git\mingw64\bin;C:\Program Files\Git\usr\bin;C:\Users\Admin\bin;C:\Program Files\Python39\Scripts;C:\Program Files\Python39;C:\Program Files\Common Files\Oracle\Java\javapath;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0;C:\Windows\System32\OpenSSH;C:\Program Files\nodejs;C:\Program Files\Git\cmd;C:\Program Files\Java\jdk-11.0.9\bin;C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files\Amazon\AWSCLIV2;C:\Users\Admin\AppData\Local\Microsoft\WindowsApps;C:\Users\Admin\AppData\Local\Programs\Microsoft VS Code\bin;C:\Users\Admin\AppData\Roaming\npm;C:\Program Files (x86)\Terraform;C:\Users\Admin\AppData\Roaming\Python\Python39\Scripts
9 verbose lifecycle data-central#1.0.0~test: CWD: E:\The expert Institute\data-central-backend
10 silly lifecycle data-central#1.0.0~test: Args: [ '/d /s /c', "mocha './tests/*.test.js'" ]
11 silly lifecycle data-central#1.0.0~test: Returned: code: 1 signal: null
12 info lifecycle data-central#1.0.0~test: Failed to exec test script
13 verbose stack Error: data-central#1.0.0 test: `mocha './tests/*.test.js'`
13 verbose stack Exit status 1
13 verbose stack at EventEmitter.<anonymous> (C:\Program Files\nodejs\node_modules\npm\node_modules\npm-lifecycle\index.js:332:16)
13 verbose stack at EventEmitter.emit (events.js:315:20)
13 verbose stack at ChildProcess.<anonymous> (C:\Program Files\nodejs\node_modules\npm\node_modules\npm-lifecycle\lib\spawn.js:55:14)
13 verbose stack at ChildProcess.emit (events.js:315:20)
13 verbose stack at maybeClose (internal/child_process.js:1048:16)
13 verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js:288:5)
14 verbose pkgid data-central#1.0.0
15 verbose cwd E:\The expert Institute\data-central-backend
16 verbose Windows_NT 10.0.19042
17 verbose argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "run" "test"
18 verbose node v14.15.4
19 verbose npm v6.14.10
20 error code ELIFECYCLE
21 error errno 1
22 error data-central#1.0.0 test: `mocha './tests/*.test.js'`
22 error Exit status 1
23 error Failed at the data-central#1.0.0 test script.
23 error This is probably not a problem with npm. There is likely additional logging output above.
24 verbose exit [ 1, true ]
Operating system - windows 10
Node version - 14 LTS
NPM version - 6.14.10
Answer to this problem was very quite simple. My node server was already running on port 3000. now when I ran npm test, chai-http was starting the node server again see this line
no two server can run on same port, so my node process was exiting upon port conflict and it wasn't giving me any error that why my test was not working

How do I solve an nexe compilation code 2 error?

I am trying to compile my node server using nexe (3.3.2) but it keeps failing. When I first tried, it said I needed to use the --build flag which I included in my script. The process kicked off again, compiled for over two hours and then failed.
I upgraded my node and npm versions using Homebrew, it didn't work. I thought it might be the size of the folders I've included but even if I just include my server.js, it fails.
Does anyone have any ideas for me please? Below is a copy of the latest log file.
0 info it worked if it ends with ok
1 verbose cli [
1 verbose cli '/usr/local/lib/node_modules/node/bin/node',
1 verbose cli '/usr/local/bin/npm',
1 verbose cli 'run',
1 verbose cli 'build'
1 verbose cli ]
2 info using npm#6.14.4
3 info using node#v13.8.0
4 verbose run-script [ 'prebuild', 'build', 'postbuild' ]
5 info lifecycle robson-callcentre#0.1.0~prebuild: robson-callcentre#0.1.0
6 info lifecycle robson-callcentre#0.1.0~build: robson-callcentre#0.1.0
7 verbose lifecycle robson-callcentre#0.1.0~build: unsafe-perm in lifecycle true
8 verbose lifecycle robson-callcentre#0.1.0~build: PATH: /usr/local/lib/node_modules/npm/node_modules/npm-lifecycle/node-gyp-bin:/Users/darryllrobinson/Documents/projects/Source/fonebookeohcollections/server/node_modules/.bin:/usr/local/opt/openssl/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/go/bin
9 verbose lifecycle robson-callcentre#0.1.0~build: CWD: /Users/darryllrobinson/Documents/projects/Source/fonebookeohcollections/server
10 silly lifecycle robson-callcentre#0.1.0~build: Args: [ '-c', 'nexe server.js --build' ]
11 silly lifecycle robson-callcentre#0.1.0~build: Returned: code: 1 signal: null
12 info lifecycle robson-callcentre#0.1.0~build: Failed to exec build script
13 verbose stack Error: robson-callcentre#0.1.0 build: `nexe server.js --build`
13 verbose stack Exit status 1
13 verbose stack at EventEmitter.<anonymous> (/usr/local/lib/node_modules/npm/node_modules/npm-lifecycle/index.js:332:16)
13 verbose stack at EventEmitter.emit (events.js:321:20)
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:321:20)
13 verbose stack at maybeClose (internal/child_process.js:1026:16)
13 verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js:286:5)
14 verbose pkgid robson-callcentre#0.1.0
15 verbose cwd /Users/darryllrobinson/Documents/projects/Source/fonebookeohcollections/server
16 verbose Darwin 19.4.0
17 verbose argv "/usr/local/lib/node_modules/node/bin/node" "/usr/local/bin/npm" "run" "build"
18 verbose node v13.8.0
19 verbose npm v6.14.4
20 error code ELIFECYCLE
21 error errno 1
22 error robson-callcentre#0.1.0 build: `nexe server.js --build`
22 error Exit status 1
23 error Failed at the robson-callcentre#0.1.0 build script.
23 error This is probably not a problem with npm. There is likely additional logging output above.
24 verbose exit [ 1, true ]
I wasn't able to resolve the problem so I used pkg instead.

Angular running error Object prototype may only be an Object or null: undefined

I have Angular application with several npm dependency in package.json. When i try to install the npm dependency npm i getting some sha1 seems to be corrupted issue. For that I delete the package-lock.json and then i can install all the npm dependency successfully. But npm start can't able to run the application showing error as
An unhandled exception occurred: Object prototype may only be an Object or null: undefined
Error log
0 info it worked if it ends with ok
1 verbose cli [ 'C:\\Program Files\\nodejs\\node.exe',
1 verbose cli 'C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js',
1 verbose cli 'start' ]
2 info using npm#6.4.1
3 info using node#v10.15.0
4 verbose run-script [ 'prestart', 'start', 'poststart' ]
5 info lifecycle ruf-stable#0.0.0~prestart: ruf-stable#0.0.0
6 info lifecycle ruf-stable#0.0.0~start: ruf-stable#0.0.0
7 verbose lifecycle ruf-stable#0.0.0~start: unsafe-perm in lifecycle true
8 verbose lifecycle ruf-stable#0.0.0~start: PATH: C:\Program Files\nodejs\node_modules\npm\node_modules\npm-lifecycle\node-gyp-bin;C:\workspace\myworkspace\2020\fis-employee-ui\node_modules\.bin;C:\Program Files (x86)\Common Files\Oracle\Java\javapath;C:\windows\system32;C:\windows;C:\windows\System32\Wbem;C:\windows\System32\WindowsPowerShell\v1.0\;C:\windows\System32\OpenSSH\;C:\Program Files (x86)\Git\cmd;C:\Program Files\PuTTY\;C:\Program Files\nodejs\;C:\Program Files\Java\jdk1.8.0_212\bin;C:\Program Files\Java\jre1.8.0_212\bin;C:\Program Files (x86)\MySQL\MySQL Utilities 1.6\;C:\Users\e5608029\AppData\Local\Programs\Python\Python37\Scripts\;C:\Users\e5608029\AppData\Local\Programs\Python\Python37\;C:\Users\e5608029\AppData\Local\Microsoft\WindowsApps;C:\Users\e5608029\AppData\Roaming\npm;C:\Users\e5608029\AppData\Local\Programs\Microsoft VS Code\bin
9 verbose lifecycle ruf-stable#0.0.0~start: CWD: C:\workspace\myworkspace\2020\fis-employee-ui
10 silly lifecycle ruf-stable#0.0.0~start: Args: [ '/d /s /c',
10 silly lifecycle 'ng serve --host 0.0.0.0 --proxy-config proxy.conf.json' ]
11 info lifecycle ruf-stable#0.0.0~start: Failed to exec start script
12 verbose stack Error: ruf-stable#0.0.0 start: `ng serve --host 0.0.0.0 --proxy-config proxy.conf.json`
12 verbose stack spawn ENOENT
12 verbose stack at ChildProcess.<anonymous> (C:\Program Files\nodejs\node_modules\npm\node_modules\npm-lifecycle\lib\spawn.js:48:18)
12 verbose stack at ChildProcess.emit (events.js:182:13)
12 verbose stack at maybeClose (internal/child_process.js:962:16)
12 verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js:251:5)
13 verbose pkgid ruf-stable#0.0.0
14 verbose cwd C:\workspace\myworkspace\2020\fis-employee-ui
15 verbose Windows_NT 10.0.17134
16 verbose argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "start"
17 verbose node v10.15.0
18 verbose npm v6.4.1
19 error file C:\windows\system32\cmd.exe
20 error code ELIFECYCLE
21 error errno ENOENT
22 error syscall spawn
23 error ruf-stable#0.0.0 start: `ng serve --host 0.0.0.0 --proxy-config proxy.conf.json`
23 error spawn ENOENT
24 error Failed at the ruf-stable#0.0.0 start script.
24 error This is probably not a problem with npm. There is likely additional logging output above.
25 verbose exit [ 1, true ]
Try npm install again after deleting the existing file. then retry npm start. if still not working try to upgrade your project by 'ng update #angular/cli #angular/core' Command.
you have to do few more changed as mentioned here

expo start command not running

Using expo to work on my react native projects using expo start always worked before. Now it doesn't work, so I reinstalled node.js. I installed expo using npm install -g expo-cli but expo start gave me:
'expo' is not recognized as an internal or external command,
operable program or batch file.
I checked my error file and this is what it says:
0 info it worked if it ends with ok
1 verbose cli [ 'C:\\Program Files\\nodejs\\node.exe',
1 verbose cli 'C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js',
1 verbose cli 'start' ]
2 info using npm#6.4.1
3 info using node#v10.14.2
4 verbose run-script [ 'prestart', 'start', 'poststart' ]
5 info lifecycle #~prestart: #
6 info lifecycle #~start: #
7 verbose lifecycle #~start: unsafe-perm in lifecycle true
8 verbose lifecycle #~start: PATH: C:\Program Files\nodejs\node_modules\npm\node_modules\npm-lifecycle\node-gyp-bin;C:\Users\Linda\Documents\U of T Engineering\2018\Jobs\IoT for Education\alarmApp\node_modules\.bin;C:\Python27\;C:\Python27\Scripts;C:\ProgramData\Boxstarter;C:\Program Files (x86)\Common Files\Oracle\Java\javapath;C:\ProgramData\Oracle\Java\javapath;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0\;C:\Program Files\Intel\WiFi\bin\;C:\Program Files\Common Files\Intel\WirelessCommon\;C:\TDM-GCC-64\bin;C:\Program Files\Git\cmd;C:\Python3;C:\Python3\Scripts;C:\Program Files\PuTTY\;C:\Program Files\MATLAB\R2017b\bin;C:\Go\bin;C:\WINDOWS\System32\OpenSSH\;C:\ProgramData\chocolatey\bin;C:\xampp\php;C:\ProgramData\ComposerSetup\bin;C:\Program Files\nodejs\;C:\Users\Linda\AppData\Local\Programs\Python\Python36-32\Scripts\;C:\Users\Linda\AppData\Local\Programs\Python\Python36-32\;C:\Users\Linda\AppData\Local\Microsoft\WindowsApps;C:\Users\Linda\AppData\Local\atom\bin;C:\altera_lite\16.0\modelsim_ase\win32aloem;C:\Users\Linda\AppData\Local\Microsoft\WindowsApps;C:\Users\Linda\go\bin;C:\Program Files\Docker Toolbox;;C:\Program Files\Docker Toolbox;C:\Program Files\Docker Toolbox;C:\Users\Linda\AppData\Roaming\Composer\vendor\bin;C:\Users\Linda\AppData\Roaming\npm
9 verbose lifecycle #~start: CWD: C:\Users\Linda\Documents\U of T Engineering\2018\Jobs\IoT for Education\alarmApp
10 silly lifecycle #~start: Args: [ '/d /s /c', 'expo start' ]
11 silly lifecycle #~start: Returned: code: 1 signal: null
12 info lifecycle #~start: Failed to exec start script
13 verbose stack Error: # start: `expo start`
13 verbose stack Exit status 1
13 verbose stack at EventEmitter.<anonymous> (C:\Program Files\nodejs\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> (C:\Program Files\nodejs\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 C:\Users\Linda\Documents\U of T Engineering\2018\Jobs\IoT for Education\alarmApp
16 verbose Windows_NT 10.0.17134
17 verbose argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "start"
18 verbose node v10.14.2
19 verbose npm v6.4.1
20 error code ELIFECYCLE
21 error errno 1
22 error # start: `expo start`
22 error Exit status 1
23 error Failed at the # start script.
23 error This is probably not a problem with npm. There is likely additional logging output above.
24 verbose exit [ 1, true ]
I have no idea why expo stopped working and what the error file means. Please help! Thanks.
I fixed it! I don't know why this works but:
npm i expo-cli then run npm start.
First check if /users/[you]/.npm-global/bin is in your path.
echo $PATH
If it isn’t there, you will need to add it to the path.
in a shell type:
export PATH=$PATH:~/.npm-global/bin
source ~/.bash_profile
if you run
> expo
in the shell now, the command should be recognized...
Use the vscode terminal, after clearing cache
Try these commands, I have fixed the issue. Try it
expo r -c
For some reason, the update messed with the path. So I had to go to edit environment variables and add another line to the variable "Path" under the system variables.
Don't hit new. Click on "Path" under the system variables section and add a new line there. Use "%USERPROFILE%\AppData\Roaming\npm".
Then open a new command line and it should work.

NPM run-script init-cloudsql skipping user prompt

I'm just starting here so sorry in advance if this seems obvious,
I've been getting myself accustomed with the appengine back-end and am following Google's bookshelf example as a start.
Everything was going okay until I run the NPM run-script init-cloudsql command and for some reason after I enter the host IP of my db the cmd skips the user prompt and asks me for the password. Then it tried to launch the script with an anonymous user.
I'm following the instructions as described, I get no errors in the previous steps.
Below is the log of my run-script:
0 info it worked if it ends with ok
1 verbose cli [ 'C:\\Program Files\\nodejs\\node.exe',
1 verbose cli 'C:\\Users\\barda\\AppData\\Roaming\\npm\\node_modules\\npm\\bin\\npm-cli.js',
1 verbose cli 'run-script',
1 verbose cli 'init-cloudsql' ]
2 info using npm#3.5.0
3 info using node#v4.2.2
4 verbose run-script [ 'preinit-cloudsql', 'init-cloudsql', 'postinit-cloudsql' ]
5 info lifecycle nodejs-getting-started#1.0.0~preinit-cloudsql: nodejs-getting-started#1.0.0
6 silly lifecycle nodejs-getting-started#1.0.0~preinit-cloudsql: no script for preinit-cloudsql, continuing
7 info lifecycle nodejs-getting-started#1.0.0~init-cloudsql: nodejs-getting-started#1.0.0
8 verbose lifecycle nodejs-getting-started#1.0.0~init-cloudsql: unsafe-perm in lifecycle true
9 verbose lifecycle nodejs-getting-started#1.0.0~init-cloudsql: PATH: C:\Users\barda\AppData\Roaming\npm\node_modules\npm\bin\node-gyp-bin;C:\nodejs-getting-started-2-structured-data\node_modules\.bin;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0\;C:\Program Files (x86)\Skype\Phone\;C:\apache-maven-3.3.9\bin\;C:\Users\barda\AppData\Local\Google\Cloud SDK\google-cloud-sdk\bin;C:\Users\barda\AppData\Roaming\npm;C:\Program Files\nodejs\
10 verbose lifecycle nodejs-getting-started#1.0.0~init-cloudsql: CWD: C:\nodejs-getting-started-2-structured-data
11 silly lifecycle nodejs-getting-started#1.0.0~init-cloudsql: Args: [ '/d /s /c', 'node books/model-cloudsql.js' ]
12 silly lifecycle nodejs-getting-started#1.0.0~init-cloudsql: Returned: code: 1 signal: null
13 info lifecycle nodejs-getting-started#1.0.0~init-cloudsql: Failed to exec init-cloudsql script
14 verbose stack Error: nodejs-getting-started#1.0.0 init-cloudsql: `node books/model-cloudsql.js`
14 verbose stack Exit status 1
14 verbose stack at EventEmitter.<anonymous> (C:\Users\barda\AppData\Roaming\npm\node_modules\npm\lib\utils\lifecycle.js:232:16)
14 verbose stack at emitTwo (events.js:87:13)
14 verbose stack at EventEmitter.emit (events.js:172:7)
14 verbose stack at ChildProcess.<anonymous> (C:\Users\barda\AppData\Roaming\npm\node_modules\npm\lib\utils\spawn.js:24:14)
14 verbose stack at emitTwo (events.js:87:13)
14 verbose stack at ChildProcess.emit (events.js:172:7)
14 verbose stack at maybeClose (internal/child_process.js:818:16)
14 verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js:211:5)
15 verbose pkgid nodejs-getting-started#1.0.0
16 verbose cwd C:\nodejs-getting-started-2-structured-data
17 error Windows_NT 10.0.10586
18 error argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Users\\barda\\AppData\\Roaming\\npm\\node_modules\\npm\\bin\\npm-cli.js" "run-script" "init-cloudsql"
19 error node v4.2.2
20 error npm v3.5.0
21 error code ELIFECYCLE
22 error nodejs-getting-started#1.0.0 init-cloudsql: `node books/model-cloudsql.js`
22 error Exit status 1
23 error Failed at the nodejs-getting-started#1.0.0 init-cloudsql script 'node books/model-cloudsql.js'.
23 error Make sure you have the latest version of node.js and npm installed.
23 error If you do, this is most likely a problem with the nodejs-getting-started package,
23 error not with npm itself.
23 error Tell the author that this fails on your system:
23 error node books/model-cloudsql.js
23 error You can get their info via:
23 error npm owner ls nodejs-getting-started
23 error There is likely additional logging output above.
24 verbose exit [ 1, true ]

Resources