Dash Exception Handling; details shown in Alert

Hey all.

I recently built a pretty extensive application with 100s callbacks. Currently, I’m attempting to make the application more reliable by handling custom exceptions. However, in the process of this, I ran into an issue I don’t know how to solve. Hoping someone might be able to help.

My goal, if possible, is to handle exceptions mostly via method decorators, then fire off an alert in the application with the custom exception message. The problem with my current framework, is I would have to consolidate all of the callbacks into a single callback to output the alert, which is not feasible. Is there another way to go about this that I’m missing?

Thanks!

You could try out the MultiplexerTransform in dash-extensions. I makes it possible to target one output (the alert) by multiple callbacks,

Thank you @Emil. Your proposed MultiplexerTransform solution is far better than trying to handle everything in one callback.

Another question, is there a way to programmatically trigger a callback? If so, was thinking I could fire a single callback that shows the alert from my exception handler. This would eliminate the need to add the alert Output to every callback in the app.

Thanks.