-
-
Notifications
You must be signed in to change notification settings - Fork 860
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
migrate from pedantic to flutter_lints #1183
Conversation
Interesting, this was far off my radar. I don't really know much on this side, but looking at https://stackoverflow.com/questions/67734486/pedantic-vs-flutter-lint-which-package-to-use-and-can-they-also-be-combined it says pedantic is deprecated. |
The semantics is almost the same and I don't think it will cause real issue. The only place where I change some code is around |
StreamSink<MapEvent> get mapEventSink; | ||
set state(MapState state); | ||
void dispose(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Here are the 3 added methods.
Thanks for your contribution! |
@@ -50,7 +50,7 @@ class _TileLoadingErrorHandleState extends State<TileLoadingErrorHandle> { | |||
tileProvider: const NonCachingNetworkTileProvider(), | |||
errorTileCallback: (Tile tile, error) { | |||
if (_needLoadingError) { | |||
WidgetsBinding.instance.addPostFrameCallback((_) { | |||
WidgetsBinding.instance?.addPostFrameCallback((_) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
on master branch of flutter WidgetsBinding.instance
is now not nullable (that's why this error occured)
Definitely a good move to migrate from Here is a detailed comparison of linting packages https://rydmike.com/blog_flutter_linting.html In the past I've done some tinkering trying to fix all "errors" that appear in this package using |
@pablojimpas I have no problem with enabling more lints but choosing the right set of rules is not the subject of this PR IMHO. For now I rely on the most consensual set for flutter packages (btw as author of several of the dartlang lints there are definitelly some of them I'll never enable on my code). Note that |
Okey I see your point, I am fine with the choice of Also, I would keep an eye on flutter/packages#1165 |
Will try to test later today. Note it might take longer than usual, as there are a lot of changes. |
This PR is stale because it has been open 45 days with no activity. Remove stale label or comment or this will be closed in 10 days. |
ping |
Sorry for the long delay. Will try to handle this soon :) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Did a bit more testing on this. I like it, and appreciate the work. Happy for anyone else to do a bit more testing as well though first, as there's quite a few files, but most look straightforward.
@ibrierley if you're happy, don't worry about my review. |
No description provided.