With Gradle 1.5 - PMD applying basic rules even when they are not included in our rule set files

We have pmdMain configuration like this:

pmdMain {

ruleSets = []

ruleSetFiles = files([















After 1.5 upgrade builds have started failing with rules not included in our rule set files. For example: [Basic Rules.CollapsibleIfStatements] - These nested if statements could be combined

This rule is not defined in any of our ruleset files. Any help is appreciated.

Looks like a regression to me, and so far I haven’t found a workaround. We’ll keep you informed.

Is there a chance this be fixed in RC2? Or should we rollback to 1.4.

If there is an RC2, it will contain a fix for this issue. We should know soon enough. In the meantime, you could try to work around with 'ruleSets = [


“$projectRoot/buildtools/pmd-rules/strictexception.xml”, …]’. I haven’t tested this, but it might work.

Awesome. That works. Thanks.

Still seems to be an issue with 1.10 The workaround does work however…