Error coderunner: npm run debug

Not sure what went wrong:

10 verbose lifecycle X-servercode@1.0.0~debug: CWD: C:...\server
11 silly lifecycle X-servercode@1.0.0~debug: Args: [ '/d /s /c', 'coderunner debug' ]
12 silly lifecycle X-servercode@1.0.0~debug: Returned: code: 1 signal: null
13 info lifecycle X-servercode@1.0.0~debug: Failed to exec debug script
14 verbose stack Error: X-servercode@1.0.0 debug: `coderunner debug`
14 verbose stack Exit status 1
14 verbose stack at EventEmitter.<anonymous> (C:....npm\node_modules\npm\lib\utils\lifecycle.js:242: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:...\npm\node_modules\npm\lib\utils\spawn.js:40: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:827:16)
14 verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js:211:5)
15 verbose pkgid X-servercode@1.0.0
16 verbose cwd C:...\server
17 error Windows_NT 6.3.9600
18 error argv "C:\\Program Files\\nodejs\\node.exe" "C...\npm\\bin\\npm-cli.js" "run" "debug"
19 error node v4.4.6
20 error npm v3.10.5
21 error code ELIFECYCLE

Hi Jonas,

Is it a full error log? Could you please provide any more information, like the sample code you’re trying to debug, JS CodeRunner’s version?

Hi,

I simply followed: https://backendless.com/documentation/business-logic/js/apieng_project_setup.htm.
I have no code yet, just an empty app folder.

Still, is it a full error log you receive and did you change the version of backendless-coderunner in package.json?

package.json:

“devDependencies”: {
“backendless-coderunner”: “>=1.4.0”
}

and error log:

12:46:05.377 - CodeRunner(tm) Backendless Debugging Utility v1.7.4
12:46:05.382 - Copyright(C) 2016 Backendless Corp. All rights reserved.
12:46:06.375 - Starting Debug Code Runner...
12:46:06.382 - Building Model..
12:46:06.383 - Model Build completed
12:46:06.384 - Error: Nothing to Debug


npm ERR! Windows_NT 6.3.9600
npm ERR! argv "C:\\Program Files\\nodejs\\node.exe" "C:...\\bin\\npm-cli.js" "run" "debug"
npm ERR! node v4.4.7
npm ERR! npm  v3.10.5
npm ERR! code ELIFECYCLE
npm ERR! X-servercode@1.0.0 debug: `coderunner debug`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the X-servercode@1.0.0 debug script 'coderunner debug
'.
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 X-servercode
package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR!     coderunner debug
npm ERR! You can get information on how to open an issue for this project with:
npm ERR!     npm bugs X-servercode
npm ERR! Or if that isn't available, you can get their info via:
npm ERR!     npm owner ls X-servercode
npm ERR! There is likely additional logging output above.


npm ERR! Please include the following file with any support request:
npm ERR!     C:\...\X\server\app\npm-debug.log

It seems because I had no code in the app folder. I’ve added an event listener and it seems to work now.

Thanks, we shall consider an improvement to avoid this error in case of an empty model.