Improve Error DX
See original GitHub issueThere have been some comments around error boundaries & general feedback to devs when errors occur.
Here is an example of a plugin with broken code.
module.exports = {
name: 'netlify-plugin-one',
onInit: () => {
console.log(thing.what) // undefined ref
},
}
or
module.exports = {
name: 'netlify-plugin-one',
onInit: () => {
throw new Error('http://www.nooooooooooooooo.com/')
},
}
Currently errors materialize like so:
Are there ways we can improve upon this?
Issue Analytics
- State:
- Created 4 years ago
- Comments:20 (18 by maintainers)
Top Results From Across the Web
How do I clear the message 'Size Error DX'? - Brother
How do I clear the message 'Size Error DX'? · 1. Press the CANCEL key to cancel the document. · 2. Choose a...
Read more >feat(nuxt): improve error dx for users by danielroe ... - GitHub
Description · fixes an issue where users who manually throw 404s can't escape from the error page (by clearing error after navigating to...
Read more >Recommendations for using the Revised Safer Dx ... - PubMed
The instrument can help users identify potential diagnostic errors in a standardized way for further analysis and safety improvement efforts as ...
Read more >Society to Improve Diagnosis in Medicine
SIDM catalyzes and leads change to improve diagnosis and eliminate harm from diagnostic error, in partnership with patients, their families, the healthcare ...
Read more >Developing the Safer Dx Checklist of Ten Safety ...
Background. Most health care organizations (HCOs) find diagnostic errors hard to address. The research team developed a checklist (the Safer Dx Checklist) ...
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 Free
Top 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
Chiming in to +1 these suggestions! I think it’s imperative we more clearly surface these errors both in the logs and the UI to avoid user confusion and churn, like @jlengstorf said:
Could we get this work prioritized as part of the #project-build-plugins-ui scope?
Once we know how this is going to work on the backend, it’d be super helpful to get an issue opened in https://github.com/netlify/netlify-react-ui/issues so we can send the UI work through our typical process: design can take these suggestions and formalize a solution, then we can send it into frontend implementation (@drewm will lead that work), Copy Club, etc. 🙂
all makes sense, and I’m on board. A couple wishlist items that I’d really like to see in place to avoid frustration/confusion later on:
1. Make it one-click to remove and rebuild when a plugin fails
this makes sense, and I’ll make a request since it sounds like we’re already building all of this functionality:
could we make the uncaught error message say something like this?
clicking the button would both turn off the build plugin and restart the deploy
2. Log unexpected failures so we can identity broken plugins/opportunities to coach plugin devs
can we make sure we’re logging the failures in an analyzable way? this would help us flag and remove plugins that are outright broken, and gives us potential to provide actionable feedback to developers (your plugin has X unexpected failures with the message “Y” — consider using
utils.build.failPlugin
to avoid these failures)