Catch GenServer #PID<0.1278.0> terminating

Is it possible to catch a possible error within handle_events which creates this exception?

[error] GenServer #PID<0.1278.0> terminating

I tried listening in the consumer to the callback def terminate(reason, state) do but is not being called.

I am wondering if genstage has some kind of error handling I can use without having to wrap handle_events in a try/catch

1 Like