spotbugs-gradle-plugin
spotbugs-gradle-plugin copied to clipboard
Still output to console when ignoreFailures=true
First off, thanks for creating and maintaining this plugin. Now for the ask.
When I run with ignoreFailures=true
, I'd still like to see what bugs it found via the console output and link to the generated report when applicable. I just don't want it to fail the task / build.
Currently it silences the console output, even though it still (silently) generates the report.
The PMD plugin minimally displays the count of bugs and a link to the report when ignoreFailures=true
:
> Task :pmdMain
Removed misconfigured rule: LoosePackageCoupling cause: No packages or classes specified
199 PMD rule violations were found. See the report at: file:///...i/build/reports/pmd/main.html
and has a boolean consoleOutput
option that when true
also reports the individual bugs to the console.
That'd be ideal from my perspective.
PMD and SpotBugs are different. In my opinion, it is not good to change what-to-be-printed by ignoreFailures
option; it seems a kind of side-effect for ignoreFailures
option and will make plugins non-intuitive and hard to control.
So if you have motivation to stop printing some in the console, I suggest you to set another report type like text
, then the console output will be calm so you can focus on other parts when you read the log.
Note that ignoreFailures
in SpotBugs makes stack traces not printed, see https://github.com/spotbugs/spotbugs-gradle-plugin/releases/tag/5.0.0 for reference.