Run clang analyzer on iOS and macOS code in CI test when packages change#2186
Run clang analyzer on iOS and macOS code in CI test when packages change#2186jmagman merged 2 commits intoflutter:masterfrom
Conversation
mklim
left a comment
There was a problem hiding this comment.
LGTM
Skip packages with known analyzer warnings.
Some linters have a concept of a "baseline" instead, where you can save all existing errors and choose to ignore them but still fail if any new errors are introduced. I checked really quickly and that doesn't seem like it's possible with pod lib lint but I'm mentioning it because if it were I think it would be preferable to totally skipping the packages that fail already.
| # These podspecs are temporary multi-platform adoption dummy files. | ||
| if [[ "${skipped_podspecs[*]}" =~ "$(basename ${podspec})" ]]; then | ||
|
|
||
| # TODO: These packages have analyzer warnings. Remove plugins from this list as issues are fixed. |
There was a problem hiding this comment.
nit: Is there a bug tracking this?
There was a problem hiding this comment.
I created issues and updated the comment.
I figure analyzing most of the projects is better than analyzing none, though locking to a baseline would be nice! |
Description
Add the
--analyzerflag during linting to run clang analyzer.Skip packages with known analyzer warnings.
I tested this by faking out a change in every package locally and confirmed this script still passes.
Related Issues
Fixes flutter/flutter#41443.
Checklist
Before you create this PR confirm that it meets all requirements listed below by checking the relevant checkboxes (
[x]). This will ensure a smooth and quick review process.///).flutter analyze) does not report any problems on my PR.Breaking Change