dispatchrun / dispatch

Entrypoint of the Dispatch ecosystem.
11 stars 1 forks source link

run: kill child process if CLI panics #47

Closed chriso closed 5 months ago

chriso commented 5 months ago

This PR ensures we kill the child process if the CLI exits with an unexpected error.

Pdeathsig helps on Linux, but it isn't available elsewhere, e.g. macOS.

I've reworked how we create background goroutines so that if a panic occurs we manually kill the child process.