globs not working in lint exclusions like Generated.txt
Categories
(Developer Infrastructure :: Lint and Formatting, defect)
Tracking
(Not tracked)
People
(Reporter: gbrown, Unassigned)
References
Details
In bug 1881094, I am moving some lint exclusions to Generated.txt. For example:
https://phabricator.services.mozilla.com/D209818
mobile/android/android-components/components/browser/engine-system/src/main/res/
mobile/android/android-components/components/browser/errorpages/src/main/res/
mobile/android/android-components/components/browser/menu/src/main/res/
...
The list of component paths may change over time, so I would prefer to make this:
mobile/android/android-components/**/src/main/res/
but that doesn't work: (license) linting is then enabled for those paths.
I also tried some variations like
mobile/android/android-components/**/src/main/res/**
but couldn't get this to work.
Comment 1•10 months ago
|
||
It looks like for some things like eslint & stylelint this should already work, however I think the main lint harness is working by directory only.
Andrew, would there be an easy way to fix this?
We might also need to check the clang plugin as that's using the file as well.
Comment 2•10 months ago
|
||
I'm not really sure what the build system or other things like the clang plugin do with that file, but I don't think mach lint
would use the linked logic there. Those files are read here:
https://searchfox.org/mozilla-central/source/tools/lint/mach_commands.py#45
Afaict, the globs are supposed to work, as it looks like we just stuff each line in the file into the exclude
key (which supports globs). Seems like there's a subtle bug somewhere. Sorry I can't say off-hand how easy this would be to fix. Requires more investigation.
Comment 3•9 months ago
|
||
The severity field is not set for this bug.
:andi, could you have a look please?
For more information, please visit BugBot documentation.
Updated•9 months ago
|
Description
•