Error trying to start development server for the first time


#1

I have tried to install the development server on 2 different windows machines and when it is time to start it I get the same error. It must be me. I have searched this error and can’t find a solution. Both times the system seems to not be able to find package.json. Please help. -

C:\WINDOWS\system32>npm run nodemon
npm ERR! Windows_NT 10.0.15063
npm ERR! argv “C:\Program Files\nodejs\node.exe” “C:\Program Files\nodejs\node_modules\npm\bin\npm-cli.js” “run” "nodemon"
npm ERR! node v6.11.4
npm ERR! npm v3.10.10
npm ERR! path C:\WINDOWS\system32\package.json
npm ERR! code ENOENT
npm ERR! errno -4058
npm ERR! syscall open

npm ERR! enoent ENOENT: no such file or directory, open 'C:\WINDOWS\system32\package.json’
npm ERR! enoent ENOENT: no such file or directory, open 'C:\WINDOWS\system32\package.json’
npm ERR! enoent This is most likely not a problem with npm itself
npm ERR! enoent and is related to npm not being able to find a file.
npm ERR! enoent

npm ERR! Please include the following file with any support request:
npm ERR! C:\WINDOWS\system32\npm-debug.log


#2

maybe your machines ran out of memory or it got auto deleted or something
idk
what is a development server anyway


#3

Sorry. I call it a development server since it sets up a web server with the development environment. I follow all the instructions (twice now) from https://github.com/codecombat/codecombat/wiki/Dev-Setup:-Windows and both times when I go to start the server I receive the same error. Each time the package.json file seems to be missing and I don’t know how the get a working install on windows. It would be great if there were a youtube walk through.

Please excuse me if I seem a little dense. I am an experienced .NET programmer and this is all new to me.


#4

So I tried npm run dev and got the same thing…

C:\WINDOWS\system32>npm run dev
npm ERR! Windows_NT 10.0.15063
npm ERR! argv “C:\Program Files\nodejs\node.exe” “C:\Program Files\nodejs\node_modules\npm\bin\npm-cli.js” “run” "dev"
npm ERR! node v6.11.4
npm ERR! npm v3.10.10
npm ERR! path C:\WINDOWS\system32\package.json
npm ERR! code ENOENT
npm ERR! errno -4058
npm ERR! syscall open

npm ERR! enoent ENOENT: no such file or directory, open 'C:\WINDOWS\system32\package.json’
npm ERR! enoent ENOENT: no such file or directory, open 'C:\WINDOWS\system32\package.json’
npm ERR! enoent This is most likely not a problem with npm itself
npm ERR! enoent and is related to npm not being able to find a file.
npm ERR! enoent

npm ERR! Please include the following file with any support request:
npm ERR! C:\WINDOWS\system32\npm-debug.log


#5

I copied a package.json file into the error location and now I have only one error:

C:\WINDOWS\system32>npm run dev
npm ERR! Windows_NT 10.0.15063
npm ERR! argv “C:\Program Files\nodejs\node.exe” “C:\Program Files\nodejs\node_modules\npm\bin\npm-cli.js” “run” "dev"
npm ERR! node v6.11.4
npm ERR! npm v3.10.10

npm ERR! missing script: dev
npm ERR!
npm ERR! If you need help, you may report this error at:
npm ERR! https://github.com/npm/npm/issues

npm ERR! Please include the following file with any support request:
npm ERR! C:\WINDOWS\system32\npm-debug.log

I don’t understand but it is not finding the script ‘dev’. Anyone know what this means?


#6

I’m dumb…I didn’t know that I had to type the ‘npm run dev’ command from within the codecombat directory. It’s all good now.


#7

ok glad you figured it out! :smiley: