-
-
Notifications
You must be signed in to change notification settings - Fork 305
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
Added pedantic lint rules. #132
Conversation
The erroneous |
Is the build breaking because of the analyze results? Or is there something else going on? |
@awhitford, Analyzing 3 directories...
info • Private field could be final • lib/src/colorize.dart:96:13 • prefer_final_fields
info • Omit type annotations for local variables • lib/src/colorize.dart:141:17 • omit_local_variable_types
info • Omit type annotations for local variables • lib/src/colorize.dart:162:5 • omit_local_variable_types
info • Omit type annotations for local variables • lib/src/fade.dart:201:5 • omit_local_variable_types
info • Omit type annotations for local variables • lib/src/fade.dart:232:5 • omit_local_variable_types
info • Omit type annotations for local variables • lib/src/fade.dart:258:9 • omit_local_variable_types
info • Omit type annotations for local variables • lib/src/rotate.dart:249:5 • omit_local_variable_types
info • Omit type annotations for local variables • lib/src/rotate.dart:280:5 • omit_local_variable_types
info • Omit type annotations for local variables • lib/src/scale.dart:226:5 • omit_local_variable_types
info • Omit type annotations for local variables • lib/src/scale.dart:257:5 • omit_local_variable_types
info • Omit type annotations for local variables • lib/src/scale.dart:283:9 • omit_local_variable_types
info • Omit type annotations for local variables • lib/src/text_liquid_fill.dart:189:10 • omit_local_variable_types
info • Omit type annotations for local variables • lib/src/typer.dart:165:5 • omit_local_variable_types
info • Omit type annotations for local variables • lib/src/typer.dart:200:5 • omit_local_variable_types
info • Omit type annotations for local variables • lib/src/typewriter.dart:179:17 • omit_local_variable_types
info • Only use double quotes for strings containing single quotes • lib/src/typewriter.dart:181:35 • prefer_single_quotes
info • Omit type annotations for local variables • lib/src/typewriter.dart:212:5 • omit_local_variable_types
info • Omit type annotations for local variables • lib/src/typewriter.dart:253:5 • omit_local_variable_types
info • Omit type annotations for local variables • lib/src/wavy.dart:123:5 • omit_local_variable_types
info • Omit type annotations for local variables • lib/src/wavy.dart:156:5 • omit_local_variable_types
info • Private field could be final • lib/src/wavy.dart:175:25 • prefer_final_fields
info • Use isEmpty instead of length • lib/src/wavy.dart:179:9 • prefer_is_empty
info • DO use curly braces for all flow control structures • lib/src/wavy.dart:185:7 • curly_braces_in_flow_control_structures
info • Omit type annotations for local variables • lib/src/wavy.dart:185:12 • omit_local_variable_types
info • Omit type annotations for local variables • lib/src/wavy.dart:191:11 • omit_local_variable_types
info • Omit type annotations for local variables • lib/src/wavy.dart:229:5 • omit_local_variable_types
info • Omit type annotations for local variables • lib/src/wavy.dart:230:5 • omit_local_variable_types
info • Omit type annotations for local variables • lib/src/wavy.dart:231:5 • omit_local_variable_types
info • Omit type annotations for local variables • lib/src/wavy.dart:232:5 • omit_local_variable_types
info • Omit type annotations for local variables • lib/src/wavy.dart:233:5 • omit_local_variable_types
info • Omit type annotations for local variables • lib/src/wavy.dart:273:5 • omit_local_variable_types
info • Omit type annotations for local variables • lib/src/wavy.dart:280:10 • omit_local_variable_types
info • Avoid relative imports for files in `lib/` • test/smoke_test.dart:3:8 • avoid_relative_lib_imports |
I didn't realize those warning would break the build. I fixed all but one with #133. Does the build need to have zero? |
@awhitford, every build needs to have zero warnings in order to pass the tests. info • Avoid relative imports for files in `lib/` • test/smoke_test.dart:3:8 • avoid_relative_lib_imports |
I'm unclear how to best resolve the last one: avoid_relative_lib_imports.
|
Codecov Report
@@ Coverage Diff @@
## master #132 +/- ##
=======================================
Coverage 72.36% 72.36%
=======================================
Files 8 8
Lines 760 760
=======================================
Hits 550 550
Misses 210 210 Continue to review full report at Codecov.
|
@aagarwal1012 OK, it's ready now. |
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.
lgtm
This enables a bunch of wise rules for
flutter analyze
and helps promote code quality.Note that there is a minor bug where
include_file_not_found
is erroneously reported, but the rules are still being checked.