Don't swallow errors
See original GitHub issueThe fact this middleware swallows errors makes debugging hard. I think for the very least in addition to marking error: true
it would be useful to call a hook notifying the user of the error - at least when debugging.
Issue Analytics
- State:
- Created 8 years ago
- Comments:5
Top Results From Across the Web
Do Not Swallow The Exceptions | Justin James
However this is my least favorite way to not swallow exception as you are still technically swallowing the error but you can at...
Read more >Why do programmers sometimes silently swallow exceptions?
BTW a bad reason I've heard from several people who I generally think are pretty good programmers is: "I don't want to display...
Read more >Error hiding - Wikipedia
In computer programming, error hiding (or error swallowing) is the practice of catching an error or exception, and then continuing without logging, ...
Read more >Do not swallow exceptions - Semicolon & Sons
An example from JavaScript. In my Javsacript client, this mistake manifested within error handlers: { onError: function (err) ...
Read more >Swallowed Exceptions: The Silent Killer of Java Applications
Let's make swallowed exceptions a thing of the past. No more empty catch blocks, and no more unknown errors. Does the scenario we...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@pocesar native promises and most libraries (NPO and RSVP lagging behind, but it’s not a huge deal anymore) now emit warnings. This issue was about getting some indication about the error.
Note that this issue is old, and has since been addressed in both popular middlewares that do promises, I just forgot to close it.
that’s actually how promises work. if you decide to use something like bluebird, it’ll emit verbose warnings with stacktraces about unhandled rejections. you’re in charge of handling your errors (as you would in try / catch statements, if / elses, etc) plus it already propagate the rejection after dispatching the error https://github.com/acdlite/redux-promise/blob/master/src/index.js#L20