quilt-loader
quilt-loader copied to clipboard
Certain legacy server versions crash while trying to load mods
When trying to load a 1.7.2 server with Quilt and a mod, the game crashes due to a MixinTargetAlreadyLoadedException
. With the help of @SpaceWalkerRS, we tested on other versions and found that the same issue exists in 1.8.9, but not 1.9 nor 1.6.4.
I looked into it more deeply and found that the log4j2.xml file in 1.7.2 is slightly different from the one in 1.9; more specifically, the packages
attribute in the Configuration
element lists net.minecraft
and com.mojang
in 1.7.2, whereas 1.9 only lists com.mojang.util
. I guess while trying to find Log4j plugins, the class loader loads every class within the listed packages, in turn loading Minecraft classes earlier than anticipated and breaking Mixin processing. (The server jar started bundling Log4j in 13w39a, any older versions don't have the class loading issue, seemingly because they don't use Log4j.)
While stepping through the code in a debugger, I found that there's a mechanism in KnotClassDelegate
that restricts certain classes from being loaded, so I think this issue might have something to do with that?