On Thursday, December 15, 2016 at 9:17:09 AM UTC+4, Miki Tebeka wrote: > > You can probably add a defer/recover to your main which will "catch" > panics, report the panic and stack trace and then exit your program with > non zero code. >
This won't work. Because it's not possible to recover one goroutine from another goroutine. On Thursday, December 15, 2016 at 9:17:09 AM UTC+4, Miki Tebeka wrote: > > You can probably add a defer/recover to your main which will "catch" > panics, report the panic and stack trace and then exit your program with > non zero code. > > However you can probably use supervisor events ( > http://supervisord.org/events.html#events > <http://www.google.com/url?q=http%3A%2F%2Fsupervisord.org%2Fevents.html%23events&sa=D&sntz=1&usg=AFQjCNEfTrC06AFs7-ggQgp-EMWA_6tAzw>) > > to get the same effect without changing your code. > We have runit as a supervisor. And we still need to report available info about error (e.g. stack trace). -- You received this message because you are subscribed to the Google Groups "golang-nuts" group. To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.