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

[flutter_lints] Consider including discarded_futures and unawaited_futures #147119

Open
stephane-archer opened this issue Apr 20, 2024 · 5 comments
Labels
c: new feature Nothing broken; request for a new capability c: proposal A detailed proposal for a change to Flutter p: flutter_lints flutter/packages flutter_lints P2 Important issues not at the top of the work list package flutter/packages repository. See also p: labels. team-ecosystem Owned by Ecosystem team triaged-ecosystem Triaged by Ecosystem team

Comments

@stephane-archer
Copy link

Use case

I did not understand correctly how to you async and Futur the right way because these two linter rules are not activated by default

  - discarded_futures
  - unawaited_futures

Proposal

I think they should be activated by default or at least mentioned in https://dart.dev/codelabs/async-await
that would have avoided a lot of pain in my learning...

@bartekpacia
Copy link
Member

I remember when I was a beginner Flutter dev, and was confused by it as well. Then I learned about these 2 rules and it "clicked" :)

@darshankawar darshankawar added the in triage Presently being triaged by the triage team label Apr 22, 2024
@darshankawar
Copy link
Member

@stephane-archer
Are you proposing to activate these lints in flutter_lints package ?

I think they should be activated by default or at least mentioned in https://dart.dev/codelabs/async-await

This will probably go in dart-lang's website repo from documentation point of view.

@darshankawar darshankawar added the waiting for customer response The Flutter team cannot make further progress on this issue until the original reporter responds label Apr 22, 2024
@stephane-archer
Copy link
Author

@darshankawar exactly :)

@github-actions github-actions bot removed the waiting for customer response The Flutter team cannot make further progress on this issue until the original reporter responds label Apr 22, 2024
@stephane-archer
Copy link
Author

dart-lang/site-www#5740

@darshankawar darshankawar added c: new feature Nothing broken; request for a new capability package flutter/packages repository. See also p: labels. c: proposal A detailed proposal for a change to Flutter team-ecosystem Owned by Ecosystem team p: flutter_lints flutter/packages flutter_lints and removed in triage Presently being triaged by the triage team labels Apr 23, 2024
@stuartmorgan stuartmorgan changed the title activate or mention in the doc when learning async discarded_futures and unawaited_futures lint rules [flutter_lints] Consider including discarded_futures and unawaited_futures Apr 23, 2024
@stuartmorgan
Copy link
Contributor

Retitling to reflect what is being requested.

@stuartmorgan stuartmorgan added P2 Important issues not at the top of the work list triaged-ecosystem Triaged by Ecosystem team labels Apr 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
c: new feature Nothing broken; request for a new capability c: proposal A detailed proposal for a change to Flutter p: flutter_lints flutter/packages flutter_lints P2 Important issues not at the top of the work list package flutter/packages repository. See also p: labels. team-ecosystem Owned by Ecosystem team triaged-ecosystem Triaged by Ecosystem team
Projects
None yet
Development

No branches or pull requests

4 participants