react-starter-kit icon indicating copy to clipboard operation
react-starter-kit copied to clipboard

Error: Server terminated unexpectedly with code: null signal: SIGTERM

Open mohanramphp opened this issue 10 years ago • 19 comments

`> @ start C:\mohan\experiments\react\boilerplates\MyApp

babel-node tools/run start

[12:12:57] Starting 'start'... [12:12:57] Starting 'clean'... [12:12:58] Finished 'clean' after 49 ms [12:12:58] Starting 'bound copy'... [12:12:58] Finished 'bound copy' after 162 ms webpack built 869f3b2ac4a25f52f21e in 9500ms Child Time: 9500ms Asset Size Chunks Chunk Names main.js?869f3b2ac4a25f52f21e 4.19 MB 0 [emitted] main Child Time: 8319ms Asset Size Chunks Chunk Names ../../server.js 197 kB 0 [emitted] main ../../server.js.map 213 kB 0 [emitted] main webpack: bundle is now VALID. webpack: bundle is now INVALID. webpack building... webpack built 869f3b2ac4a25f52f21e in 502ms Child Time: 502ms Child Time: 8319ms Asset Size Chunks Chunk Names ../../server.js 197 kB 0 [emitted] main ../../server.js.map 213 kB 0 [emitted] main webpack: bundle is now VALID. C:\mohan\experiments\react\boilerplates\MyApp\tools\runServer.js:71 throw new Error(`Server terminated unexpectedly with code: ${ cod ^

Error: Server terminated unexpectedly with code: null signal: SIGTERM at ChildProcess.server.once (runServer.js:53:15) at ChildProcess.g (events.js:286:16) at emitTwo (events.js:106:13) at ChildProcess.emit (events.js:191:7) at Process.ChildProcess._handle.onexit (internal/child_process.js:204

npm ERR! Windows_NT 6.1.7601 npm ERR! argv "C:\Program Files\nodejs\node.exe" "C:\Program Files\n npm ERR! node v6.2.0 npm ERR! npm v3.8.9 npm ERR! code ELIFECYCLE npm ERR! @ start: babel-node tools/run start npm ERR! Exit status 1 npm ERR! npm ERR! Failed at the @ start script 'babel-node tools/run start'. npm ERR! Make sure you have the latest version of node.js and npm install npm ERR! If you do, this is most likely a problem with the package, npm ERR! not with npm itself. npm ERR! Tell the author that this fails on your system: npm ERR! babel-node tools/run start npm ERR! You can get information on how to open an issue for this project npm ERR! npm bugs npm ERR! Or if that isn't available, you can get their info via: npm ERR! npm owner ls npm ERR! There is likely additional logging output above.

npm ERR! Please include the following file with any support request: npm ERR! C:\mohan\experiments\react\boilerplates\MyApp\npm-debug.log`

I am new to react starter kit. Following things i have done

  1. git clone -o react-starter-kit -b master --single-branch https://github.com/kriasoft/react-starter-kit.git MyApp
  2. npm install
  3. npm start [Hed this issue]

Please help.

mohanramphp avatar Jul 20 '16 07:07 mohanramphp

I had the same issue. I'm attaching the npm-debug.log file generated on my machine. npm-debug.log

garfieldnate avatar Oct 17 '16 01:10 garfieldnate

@mohanramphp looks like server terminated after breaking hot update, if so here is the fix: #918

frenzzy avatar Oct 17 '16 06:10 frenzzy

@frenzzy I checkout out #918 and it works on Windows! Japanese Windows, no less. Thanks!

garfieldnate avatar Oct 18 '16 01:10 garfieldnate

Should be solved by #918. Please reopen if needed.

frenzzy avatar Oct 22 '16 12:10 frenzzy

I pulled from master yesterday. I still get this exception!

broncha avatar Nov 15 '16 07:11 broncha

I got the same issue. @frenzzy

xiguaaxigua avatar Nov 22 '16 11:11 xiguaaxigua

Same issue

jshjohnson avatar Nov 29 '16 15:11 jshjohnson

+1

PetrochukM avatar Nov 30 '16 00:11 PetrochukM

Pulled yesterday, and still get this exception. I'm on Mac, NPM v3.8.6 (also on 4.0.2) and Node v6.5.

codeorelse avatar Nov 30 '16 18:11 codeorelse

samsies

pvijeh avatar Dec 11 '16 21:12 pvijeh

+1

Mykybo avatar Dec 13 '16 16:12 Mykybo

anybody figure this out?

pvijeh avatar Dec 23 '16 19:12 pvijeh

+1 - Same error, more extensive repro steps though.

Host Machine: macOS Docker Container: node:7.2.1-alpine react-starter-kit #1044

Basically, I'm running docker-compose up (my Dockerfile and docker-compose.yml) and everything runs perfect. I can view the site from a browser on the host machine, even got HMR working.

However, editing/saving src files too quickly causes this error, which crashes the container.

It's a showstopper for us since it happens each time and have far too long of a recovery to restart the container.

iDVB avatar Dec 27 '16 04:12 iDVB

@iDVB you can solve this temporarily by commenting out lines 51 through 57 in tools/runServer.js

// if (pending) {
//   server.once('exit', (code, signal) => {
//     if (pending) {
//       throw new Error(`Server terminated unexpectedly with code: ${code} signal: ${signal}`);
//     }
//   });
// }

Im not sure what the root cause of the error is, but commetting these lines out does not seem to have any ill effect and will solve the problem and let you start working again.

pvijeh avatar Dec 27 '16 04:12 pvijeh

@pvijeh Woot! FIXED Thanks! You have no idea how much time that likely saved me. I've spend about 5 hours trying to get as much as I have working now... only to see that error. It's my docker first, so I was almost about to ditch docker.

iDVB avatar Dec 27 '16 04:12 iDVB

+1 getting this error and just pulled the project 2 months ago. Commenting the lines out loads the server but not vendor and client.js so functionality is useless

ryanbelke avatar Jul 03 '17 03:07 ryanbelke

solved with deleting the .yarnlock file and running yarn again

ryanbelke avatar Jul 03 '17 03:07 ryanbelke

are you sure fix the issues? I still have the same issues, heart break

TristanDongMaster avatar Feb 05 '18 07:02 TristanDongMaster

same here !

khashayarghajar avatar Mar 28 '23 17:03 khashayarghajar