utilities icon indicating copy to clipboard operation
utilities copied to clipboard

Make BackgroundActionQueue catch exceptions

Open paulcscharf opened this issue 3 years ago • 0 comments

🆙 Improvement proposal

At present, the BackgroundActionQueue will break if any actions executed throw. While the user can catch and handle their own exception, we should consider doing this for them, and offering various methods of getting at those errors (like the Result monad).

Context

Exceptions and threads are a real pain. Best to make that interface as easy as possible and prevent things from blowing up in a user's face.

EDIT: ManualActionQueue has the same problem. Also worth noting is that calls to RunAndAwait will never return if the action throws, which is even worse than the queue breaking.

paulcscharf avatar Oct 14 '20 15:10 paulcscharf