spotbugs-gradle-plugin icon indicating copy to clipboard operation
spotbugs-gradle-plugin copied to clipboard

SpotbugsTask is considered up-to-date after adding a spotbugsPlugins dependency

Open jochenberger opened this issue 2 years ago • 2 comments

If I add a spotbugs plugin (e.g. spotbugsPlugins 'com.h3xstream.findsecbugs:findsecbugs-plugin:1.11.0') and run the spotbugsMain task, it is considered up-to-date. The plugins should be considered for the up-to-date check. Please let me know if any more information is needed.

jochenberger avatar Nov 02 '21 11:11 jochenberger

I just came across this issue too. It looks like a problem is that the task input is marked as internal:

https://github.com/spotbugs/spotbugs-gradle-plugin/blob/ba591fbb3d8016c28bb2e6d7231087e286cccc8a/src/main/groovy/com/github/spotbugs/snom/SpotBugsTask.groovy#L447

davidburstromspotify avatar May 31 '22 13:05 davidburstromspotify

Yep, should probably be @Classpath instead.

And the same for spotbugsClasspath. If you have the html report enabled and use a built-in stylesheet, the task will be out-of-date because the stylesheet property changed. But if you either have a custom stylesheet or do not have the html report enabled, the tasks are up-to-date or served from cache even if the spotbugs version is changed.

Vampire avatar Jun 26 '23 11:06 Vampire