The Travis build has been failing since #1187, for no good reason. Looking at the job, it looks like it's a lint issue (lint • Sort constructor declarations before other members at _filename_) in many of our files. I don't know why this is showing up now. The tests pass locally. Maybe it's an SDK version thing.
From the job:
$ dart --version
Dart VM version: 2.1.0-dev.7.0 (Wed Oct 10 19:57:35 2018 +0200) on "linux_x64"
Locally:
$ dart --version
Dart VM version: 2.0.0 (Fri Aug 3 10:53:23 2018 +0200) on "macos_x64"
Yep, it's an SDK version issue: after updating to 2.1.0-dev.7.0, I see these same errors (sort_constructors_first).
Related to dart-lang/linter#834?
/cc @pq @a14n
Yeah that SDK is pulling in an update to the rule. @a14n can provide some context on the change but my sense is this is fairly Flutter specific. I'd probably just remove the lint. Is this the options file you're using?
https://github.com/dart-lang/site-www/blob/master/examples/analysis_options.yaml
Yep, that's the one.
It turns out that lots of other stuff is failing, even after I pull out that rule. 2.1 is just pickier than 2.0.
Hmmmm...
Before I read your last comment, I was going to say just remove it but there may be more than that.
Another consideration: you might consider simplifying your options and grabbing the evolving google (internal) ruleset:
https://github.com/dart-lang/pedantic/
I'd be curious how things look then.
(Note: there are far fewer lints defined in pedantic so you'll get fewer checks obviously but these do have the advantage of representing a kind of "blessed" set of rules.)
Food for thought anyway!
@chalin I could use your guidance here. I don't understand our test process as well as I should.
Related to dart-lang/linter#834?
Yes this rule was done for flutter and has a bug regarding Flutter Style guide.
I guess you should simply remove this lint.
(Note: there are far fewer lints defined in pedantic so you'll get fewer checks obviously but these do have the advantage of representing a kind of "blessed" set of rules.)
Even if you use pedantic you can add additional rules like in https://github.com/dart-lang/test/blob/e097f77d3e89dc57183c23adc63126e9cc114c26/analysis_options.yaml for instance.
if you use pedantic you can add additional rules
That's the angle I'd recommend for sure. Unless @chalin feels strongly...
Sure, sounds like a good idea but @kevmoo had already started a PR (#1183) with adjustments to the analysis options, so I'll continue to work on cleaning that PR up before looking into the use of the pedantic options (which we can address in a separate PR).
Travis build has been failing
It is green as of the last PR.
It turns out that lots of other stuff is failing ...
It seems that some lints have changed names (and the old names aren't recognized anymore?):
strong_mode_invalid_method_override -> invalid_overrideinconsistent_method_inheritance -> inconsistent_inheritanceThis is a breaking change. To ease migration, could the old lints still be recognized? If not, I'm going to (try to) address this in #1183, but it might mean choosing to run tests under Dart dev only (ignoring build failures for Dart stable). @kwalrath would that be ok?
FYI, Travis is happy with #1183, though it allows Dev stable failures.
Most helpful comment
Yeah that SDK is pulling in an update to the rule. @a14n can provide some context on the change but my sense is this is fairly Flutter specific. I'd probably just remove the lint. Is this the options file you're using?
https://github.com/dart-lang/site-www/blob/master/examples/analysis_options.yaml