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

package:linter nnbd migration plan #58322

Closed
4 tasks done
pq opened this issue Feb 12, 2021 · 3 comments
Closed
4 tasks done

package:linter nnbd migration plan #58322

pq opened this issue Feb 12, 2021 · 3 comments
Assignees
Labels
analyzer-linter Issues with the analyzer's support for the linter package area-analyzer Use area-analyzer for Dart analyzer issues, including the analysis server and code completion. area-meta Cross-cutting, high-level issues (for tracking many other implementation issues, ...). type-code-health Internal changes to our tools and workflows to make them cleaner, simpler, or more maintainable

Comments

@pq
Copy link
Member

pq commented Feb 12, 2021

The package:linter migration plan:

  • 1. land an initial migration that is as tool-driven as possible that runs tests, etc in unsound mode (@pq)
  • 2. follow-up with changes to tidy up lib (e.g., remove unnecessary null operators) (@pq) (see: nnbd migration linter#2452 (review))
  • 3. cleanup tool (gated somewhat by dev_dependencies such as github) (@pq)
  • 4. fix-up build scripts and remove unsound flags (soundness fixes linter#2467)
  1. and 2. will happen before a release (3 is stretch).

Related issues:

SpinlockLabs/github.dart#236

In conversation, @bwilkerson and I agreed (again) how nice it would be to have some lints to disallow ?s and !s as this would help in tidying. (I think @scheglov is wanting something similar.)

@pq pq added type-code-health Internal changes to our tools and workflows to make them cleaner, simpler, or more maintainable area-meta Cross-cutting, high-level issues (for tracking many other implementation issues, ...). labels Feb 12, 2021
@pq pq self-assigned this Feb 12, 2021
@bwilkerson
Copy link
Member

To be clear, I don't think we want a lint to disallow ?s. There are times when they're necessary. I just want one to disallow null checks because I think they're almost always wrong.

@scheglov
Copy link
Contributor

I thought so too, that Type? and ?. are useful and are not unsafe.
But ! null checks are unsafe.

@pq
Copy link
Member Author

pq commented Feb 16, 2021

Sorry yes, I wrote in haste. I 100% agree.

@pq pq closed this as completed Mar 26, 2021
@devoncarew devoncarew added analyzer-linter Issues with the analyzer's support for the linter package area-analyzer Use area-analyzer for Dart analyzer issues, including the analysis server and code completion. labels Nov 19, 2024
@devoncarew devoncarew transferred this issue from dart-lang/linter Nov 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
analyzer-linter Issues with the analyzer's support for the linter package area-analyzer Use area-analyzer for Dart analyzer issues, including the analysis server and code completion. area-meta Cross-cutting, high-level issues (for tracking many other implementation issues, ...). type-code-health Internal changes to our tools and workflows to make them cleaner, simpler, or more maintainable
Projects
None yet
Development

No branches or pull requests

4 participants