pantomime-rs / pantomime

MIT License
5 stars 1 forks source link

Overhaul panic handling #28

Closed longshorej closed 5 years ago

longshorej commented 5 years ago

Don't rely on catch_unwind. Instead, we use deferred to check for thread panicking and message ourselves a Stop(fail = true) if that's the case.

In general, note that panics should be avoided, but sometimes unforseen things happen hence it's necessary to consider them in Pantomime.

Supervisor and Streams still need to be extended to use this mechanism, that will happen in a separate commit.