Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add to the documentation the recommended way and tradeoff for error handling. #5748

Open
1 task
stephane-archer opened this issue Apr 24, 2024 · 0 comments
Open
1 task
Labels
a.language Relates to the Dart language tour e2-days Can complete in < 5 days of normal, not dedicated, work fix.quality Needs improvement in copy quality from.page-issue Reported in a reader-filed concern p2-medium Necessary but not urgent concern. Resolve when possible. st.triage.ltw Indicates Lead Tech Writer has triaged

Comments

@stephane-archer
Copy link

Page URL

https://dart.dev/language/error-handling

Page source

No response

Describe the problem

The page about error handling only talks about Exceptions and Assert. It almost feels like exceptions are "the way" of doing error handling in Dart.
The page should discuss returning null values as errors (Type?) and how to choose when to use exception or null return values. What are the actual trade-offs in terms of performance or maintainability and what does the Dart team recommend?
With the async nature of Dart and the different platforms, I miss a lot of clarity on how to make good error handling in Dart

Expected fix

No response

Additional context

No response

I would like to fix this problem.

  • I will try and fix this problem on dart.dev.
@stephane-archer stephane-archer added the from.page-issue Reported in a reader-filed concern label Apr 24, 2024
@atsansone atsansone added a.language Relates to the Dart language tour p2-medium Necessary but not urgent concern. Resolve when possible. e2-days Can complete in < 5 days of normal, not dedicated, work st.triage.ltw Indicates Lead Tech Writer has triaged fix.quality Needs improvement in copy quality labels Apr 24, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
a.language Relates to the Dart language tour e2-days Can complete in < 5 days of normal, not dedicated, work fix.quality Needs improvement in copy quality from.page-issue Reported in a reader-filed concern p2-medium Necessary but not urgent concern. Resolve when possible. st.triage.ltw Indicates Lead Tech Writer has triaged
Projects
None yet
Development

No branches or pull requests

2 participants