node-clinic: 'Ctrl + C' not working for Mac, but works for Linux.
Expected Behavior
Bug: ‘Ctrl+C’ stops the doctor, and doesn’t even reach to the analyzing part.
Current Behavior
I am trying to run clinic against a script, which needs to be run on background calling a polling function to check if there was an event triggered from the front end. Once the event has been sent from the front end, this polling function takes care of the event. Once it’s done. I stop by using Ctrl + C, where the Analyzing bar doesn’t appear.
Environment
-
Clinic.js version: “4.0.3”,
-
Node.js version: 10.15.3, npm - 6.4.1
-
Browser name and version: Chrome Version 73.0.3683.103
-
Operating system and version: Your OS is OS X 10.14.1 [Mac OS Mojave]
Additional Info
The same command am using:
clinic doctor --on-port 'autocannon http://localhost:$PORT' -- node tasks/cathy.js works for 2 of my friends Linux PC, but not on my MAC. (Going to confirm with another MAC friend soon. Will update it here.)
About this issue
- Original URL
- State: open
- Created 5 years ago
- Reactions: 10
- Comments: 17 (6 by maintainers)
Look for the SIGINT( catches ctrl+c event) event handlers in your code or the dependencies.
if you have one,
exitthe process in the handling. This worked for me(OsXCatalina/ clinic@9.0.0)