ForgeGradle
ForgeGradle copied to clipboard
Fix: changes to ATs break multi-module projects
I'm working on a multi-module Minecraft Forge project. We were originally using a build script that compiled the dependency-modules into Jars and then had the master module depend on the Jars. I upgraded the buildscript to work as a true Gradle Multi-module project but, since then, when pulling commits that included changes to AccessTransformers, IDEA would complain about not being able to find the sources.
I think I have stumbled on the solution and would be very pleased and grateful if you could merge this PR.
Quitting early if AT_HASH
does not match athash
removes the chance for us to generate a new artifact in some scenarios when the ATs have been changed.
Making the comparison here in MinecraftUserRep::findFile
is problematic and not necessary. The HashStore
will look for a cache hit/miss in later find***
calls. The HashStore
compares the current AT_HASH
with the cached AT_HASH
and will return a Cache Miss if the ATs have changed.