SuperMartijn642 / SuperMartijn642sCoreLib

14 stars 2 forks source link

[Crash] Can no longer launch game client side #36

Closed A5ho9999 closed 1 year ago

A5ho9999 commented 1 year ago

Version Info

Steps to Reproduce na

Crash report (~/logs/latest.log)

java.lang.IllegalStateException: Registry is already frozen (trying to add key ResourceKey[minecraft:recipe_serializer / supermartijn642corelib:conditional])
    at net.minecraft.class_2370.method_40274(class_2370.java:135)
    at net.minecraft.class_2370.method_46744(class_2370.java:141)
    at net.minecraft.class_2370.method_10272(class_2370.java:186)
    at net.minecraft.class_2378.method_39197(class_2378.java:118)
    at net.minecraft.class_2378.method_10230(class_2378.java:114)
    at com.supermartijn642.core.registry.Registries$VanillaRegistryWrapper.register(Registries.java:195)
    at com.supermartijn642.core.registry.RegistrationHandler.registerEntries(RegistrationHandler.java:449)
    at com.supermartijn642.core.registry.RegistrationHandler.handleRegistry(RegistrationHandler.java:437)
    at com.supermartijn642.core.registry.RegistrationHandler.registerAll(RegistrationHandler.java:431)
    at java.base/java.util.HashMap$Values.forEach(HashMap.java:1065)
    at com.supermartijn642.core.registry.RegistrationHandler.registerInternal(RegistrationHandler.java:47)
    at com.supermartijn642.core.CoreLib.afterInitialize(CoreLib.java:71)
    at net.minecraft.class_310.handler$jei001$supermartijn642corelib$afterInitClient(class_310.java:33523)
    at net.minecraft.class_310.<init>(class_310.java:458)
    at net.minecraft.client.main.Main.main(Main.java:211)
    at net.fabricmc.loader.impl.game.minecraft.MinecraftGameProvider.launch(MinecraftGameProvider.java:468)
    at net.fabricmc.loader.impl.launch.knot.Knot.launch(Knot.java:74)
    at net.fabricmc.loader.impl.launch.knot.KnotClient.main(KnotClient.java:23)

https://gist.github.com/A5ho9999/577bd3c12afbc8cbb4e2931725866271

SuperMartijn642 commented 1 year ago

Minecraft seems to start up fine with my core library.

You seem to be using a lot of other mods, could you narrow down the mods needed to reproduce the issue?

A5ho9999 commented 1 year ago

I believe it is https://modrinth.com/mod/plant-in-a-jar

SuperMartijn642 commented 1 year ago

Ah indeed it was Plant In A Jar. It seems they are causing registries to be frozen early for some reason. I added a workaround now in version 1.1.10b. Thank you for reporting the issue!

A5ho9999 commented 1 year ago

Great, thank you!