Fabric API

Fabric API

112M Downloads

Using Kotlin in Prelaunch causes Indigo to classload Kotlin

ejektaflex opened this issue ยท 2 comments

commented

Hi, I'm not sure exactly whether this is for the Fabric Language Kotlin or the Fabric issue tracker, but when upgrading my mod from 23w07a to 1.19.4 I get a crash when loading the game:

err.txt

My mod (Bountiful) relies in my library mod (Kambrik). Kambrik searches for entrypoint containers during prelaunch so that it can do automatic content registration. It seems to me that Indigo has a mixin that classloads Kotlin because of my prelaunch initializer (hence the Mixin transformation of kotlin.jvm.internal.Intrinsics failed).

I'm not sure what would have caused this, but my initial thought it that it would be something related to Indigo?

Library source: https://github.com/ejektaflex/Kambrik/tree/1.19
Mod source: https://github.com/ejektaflex/Bountiful-Fabric

commented

This is caused by a loom bug (that has no good fix sadly) it happens when one of your dependencies (in your case it seems cloth-config or modmenu) uses an older version of fabric-loader on another configuration.

Adding the following to your build.gradle is a workaround:

configurations.all {
   resolutionStrategy {
      force("net.fabricmc:fabric-loader:$loader_version")
   }
}
commented

Nasty! I added that to my main mod and that has fixed the problem. Thanks much! <3