I am running Gradle 3.0 with the following JVM on MacOS
java version "1.8.0_101"
Java(TM) SE Runtime Environment (build 1.8.0_101-b13)
Java HotSpot(TM) 64-Bit Server VM (build 25.101-b13, mixed mode)
My Findbugs plugin config looks like this:
findbugs {
toolVersion = "${findbugsVersion}"
sourceSets = [sourceSets.main]
ignoreFailures = false
reportsDir = file("$project.buildDir/findbugsReports")
effort = "max"
reportLevel = "low"
includeFilter = file("$rootProject.projectDir/findbugs-rules.xml")
}
findbugsMain {
reports {
xml.enabled = false
html.enabled = true
}
}
My includeFilter looks like this:
<FindBugsFilter>
<Match>
<Confidence value="2"/>
<Rank value="20"/>
<Bug category="CORRECTNESS,MT_CORRECTNESS,SECURITY,PERFORMANCE,MALICIOUS_CODE,STYLE,BAD_PRACTICE"/>
<Package name=".+" />
</Match>
</FindBugsFilter>
Then I run:
gradle findbugsMain
Regardless of what I put in the filter file, (I have played around with all kinds of values and have also put in nonsensical ones just to test) no errors or warnings are ever reported. If I remove the reference to the filter, then FB starts reporting issues in the html report.
This is with FB 3.0.1. The same config with the Maven plugin reports plenty.