Is your feature request related to a problem? Please describe.
childProcess.killed is inconsistent depending on how the child process was killed:
const { spawn } = require('child_process')
const childProcess = spawn('sleep', [5e6])
childProcess.kill()
console.log(childProcess.killed) // true
const { spawn } = require('child_process')
const childProcess = spawn('sleep', [5e6])
process.kill(childProcess.pid)
console.log(childProcess.killed) // false
Describe the solution you'd like
killed should be true when the process is killed through an external process (process.kill() or kill in the terminal).
Versions
Node 12.1.0, Ubuntu 19.04.
Is your feature request related to a problem? Please describe.
childProcess.killedis inconsistent depending on how the child process was killed:Describe the solution you'd like
killedshould betruewhen the process is killed through an external process (process.kill()orkillin the terminal).Versions
Node
12.1.0, Ubuntu19.04.