30/09/2018, 18:53

Lỗi khi khởi chạy server Node.js

Khi khởi chạy server trong node,js dưới đây là file bug . Đúng hơn là mình đã chạy được server nhưng khi client cố gắng vào index.html thì server ngừng chạy và báo lỗi kỹ hơn mọi người có thể vào link https://jsfiddle.net/m9wvm4nu/3/ dưới đây là file debug log
0 info it worked if it ends with ok 1 verbose cli [ 'C:\nodejs\node.exe', 1 verbose cli 'C:\nodejs\node_modules\npm\bin\npm-cli.js', 1 verbose cli 'start' ] 2 info using npm@3.3.12 3 info using node@v5.1.0 4 verbose run-script [ 'prestart', 'start', 'poststart' ] 5 info lifecycle simple-website@1.0.0~prestart: simple-website@1.0.0 6 silly lifecycle simple-website@1.0.0~prestart: no script for prestart, continuing 7 info lifecycle simple-website@1.0.0~start: simple-website@1.0.0 8 verbose lifecycle simple-website@1.0.0~start: unsafe-perm in lifecycle true 9 verbose lifecycle simple-website@1.0.0~start: PATH: C: odejs ode_modules pmin ode-gyp-bin;D:1-PROJECTsimple-website ode_modules.bin;C:UsersMyPCin;C:UsersMyPCAppDataLocalProgramsGitmingw64in;C:UsersMyPCAppDataLocalProgramsGitusrlocalin;C:UsersMyPCAppDataLocalProgramsGitusrin;C:UsersMyPCAppDataLocalProgramsGitusrin;C:UsersMyPCAppDataLocalProgramsGitmingw64in;C:UsersMyPCAppDataLocalProgramsGitusrin;C:UsersMyPCin;C:Windowssystem32;C:Windows;C:WindowsSystem32Wbem;C:WindowsSystem32WindowsPowerShellv1.0;C:Program Files (x86)SkypePhone;C: odejs;C:UsersMyPCAppDataLocalatomin;C:UsersMyPCAppDataLocal.meteor;C:UsersMyPCAppDataRoaming pm;C:UsersMyPCAppDataLocalProgramsGitcmd;C:UsersMyPCAppDataLocalProgramsGitmingw64in;C:UsersMyPCAppDataLocalProgramsGitusrin;C:UsersMyPCAppDataLocalProgramsGitusrinvendor_perl;C:UsersMyPCAppDataLocalProgramsGitusrincore_perl 10 verbose lifecycle simple-website@1.0.0~start: CWD: D:1-PROJECTsimple-website 11 silly lifecycle simple-website@1.0.0~start: Args: [ '/d /s /c', 'node server.js' ] 12 silly lifecycle simple-website@1.0.0~start: Returned: code: 1 signal: null 13 info lifecycle simple-website@1.0.0~start: Failed to exec start script 14 verbose stack Error: simple-website@1.0.0 start:node server.js14 verbose stack Exit status 1 14 verbose stack at EventEmitter.<anonymous> (C: odejs ode_modules pmlibutilslifecycle.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: odejs ode_modules pmlibutilsspawn.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 simple-website@1.0.0 16 verbose cwd D:1-PROJECTsimple-website 17 error Windows_NT 10.0.10240 18 error argv "C:\nodejs\node.exe" "C:\nodejs\node_modules\npm\bin\npm-cli.js" "start" 19 error node v5.1.0 20 error npm v3.3.12 21 error code ELIFECYCLE 22 error simple-website@1.0.0 start:node server.js22 error Exit status 1 23 error Failed at the simple-website@1.0.0 start script 'node server.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 simple-website package, 23 error not with npm itself. 23 error Tell the author that this fails on your system: 23 error node server.js 23 error You can get their info via: 23 error npm owner ls simple-website 23 error There is likely additional logging output above. 24 verbose exit [ 1, true ]

Bài liên quan
0