erikras / erikras/react-redux-universal-hot-example
Intermittent error running dev server
- Dominant language
- JavaScript
- Stars
- 12.1k
- Forks
- 2.5k
- PR merge metrics
- No merged PRs in 30d
Description
When loading a page from the dev server started with `npm run dev`, I often get this error message:
```
[1] [piping] can't execute file: /home/jacob/workspace/projects/react-redux-universal-hot-example/bin/server.js
[1] [piping] error given was: TypeError: res.writeHead is not a function
[1] at ProxyServer. (/home/jacob/workspace/projects/react-redux-universal-hot-example/src/server.js:56:9)
[1] at ProxyServer.emit (/home/jacob/workspace/projects/react-redux-universal-hot-example/node_modules/eventemitter3/index.js:144:27)
[1] at ClientRequest.onOutgoingError (/home/jacob/workspace/projects/react-redux-universal-hot-example/node_modules/http-proxy/lib/http-proxy/passes/ws-incoming.js:151:16)
[1] at emitOne (events.js:96:13)
[1] at ClientRequest.emit (events.js:191:7)
[1] at Socket.socketOnEnd (_http_client.js:394:9)
[1] at emitNone (events.js:91:20)
[1] at Socket.emit (events.js:188:7)
[1] at endReadableNT (_stream_readable.js:975:12)
[1] at _combinedTickCallback (internal/process/next_tick.js:80:11)
[1] [piping] further repeats of this error will be suppressed...
[1] [piping] can't execute file: /home/jacob/workspace/projects/react-redux-universal-hot-example/bin/server.js
[1] [piping] error given was: TypeError: res.writeHead is not a function
[1] at ProxyServer. (/home/jacob/workspace/projects/react-redux-universal-hot-example/src/server.js:56:9)
[1] at ProxyServer.emit (/home/jacob/workspace/projects/react-redux-universal-hot-example/node_modules/eventemitter3/index.js:144:27)
[1] at ClientRequest.onOutgoingError (/home/jacob/workspace/projects/react-redux-universal-hot-example/node_modules/http-proxy/lib/http-proxy/passes/ws-incoming.js:151:16)
[1] at emitOne (events.js:96:13)
[1] at ClientRequest.emit (events.js:191:7)
[1] at Socket.socketCloseListener (_http_client.js:334:9)
[1] at emitOne (events.js:101:20)
[1] at Socket.emit (events.js:191:7)
[1] at TCP._handle.close [as _onclose] (net.js:511:12)
[1] [piping] further repeats of this error will be suppressed...
[1] events.js:163
[1] throw er; // Unhandled 'error' event
[1] ^
[1]
[1] Error: channel closed
[1] at process.target.send (internal/child_process.js:562:16)
[1] at Worker.send (internal/cluster/worker.js:54:28)
[1] at process. (/home/jacob/workspace/projects/react-redux-universal-hot-example/node_modules/piping/lib/launcher.js:46:20)
[1] at emitOne (events.js:96:13)
[1] at process.emit (events.js:191:7)
[1] at process._fatalException (bootstrap_node.js:304:26)
```
Contributor guide
Assessment
This issue has not been assessed yet.