The ForbiddenAPI tool we use has a smart classloader cache, but it seems this interacts with the gradle daemon; in some situations this has shown to load snapshot builds from a previous build. I haven't fully understood why this happens; what I know is we're possibly loading the snapshots that the OSGi integration tests are needing to deploy into a Maven repository, so I'd guess this possibly bypasses some sanity checks from the Gradle tooling. Let's disable the cache: it solves the problem, probably avoids some future headaches and I've not seen any performance difference. |