node-clinic: premature close error on process exit
Expected Behavior
An HTML report should be saved
Current Behavior
Doctor, bubbleprof, and flame all crash with this error:
Error: premature close
at MultiStream.onclose (/Users/contra/.nvm/versions/node/v10.6.0/lib/node_modules/clinic/node_modules/end-of-stream/index.js:47:67)
at MultiStream.emit (events.js:187:15)
at MultiStream.destroy (/Users/contra/.nvm/versions/node/v10.6.0/lib/node_modules/clinic/node_modules/multistream/index.js:65:8)
at DestroyableTransform.onClose (/Users/contra/.nvm/versions/node/v10.6.0/lib/node_modules/clinic/node_modules/multistream/index.js:111:12)
at Object.onceWrapper (events.js:273:13)
at DestroyableTransform.emit (events.js:187:15)
at /Users/contra/.nvm/versions/node/v10.6.0/lib/node_modules/clinic/node_modules/through2/through2.js:20:10
at process._tickCallback (internal/process/next_tick.js:61:11)
Steps to Reproduce (for bugs)
- Node 10.6
npm install clinic -gclinic doctor -- node dummy-server.js- Wait a bit, press CTRL-C
Environment
- Clinic version: Clinic v1.1.0 Doctor v3.0.3
- Node version: v10.6
- Operating system and version: MacOS Mojave Beta
About this issue
- Original URL
- State: closed
- Created 6 years ago
- Reactions: 4
- Comments: 32 (12 by maintainers)
Same here. I’m using node v12.13.0.
Steps to repro:
transportertonullinmoleculer.config.jsclinic doctor -- npm run devautocannon http://localhost:3000/api/greeter/helloCtrl + CWhen it happens, I recommend you to:
.clinicfoldernode_trace.*.logfiles@jasnell, the thing is, I can run much larger profiles with no problems if I hack
end-of-streamwith that https://github.com/mafintosh/end-of-stream/pull/13 fix.@goto-bus-stop @DylanC … let’s make sure this issue is looked at for the next release.
I’m also having it on node 10.16.3. The fix described in https://github.com/mafintosh/end-of-stream/pull/13 fixes it completely.
I’m also running clinic doctor locally and having the same issue. I am running 6 request per second for 5 minutes (total of 1800 requests) Using clinic v4.2.0