Roughly Enough Items Fabric/Forge/NeoForge (REI)

Roughly Enough Items Fabric/Forge/NeoForge (REI)

40M Downloads

[Bug] REI Crashing on dedicated server start

warjort opened this issue ยท 5 comments

commented

Describe the bug
Running REI in dedicated server mode (at least in a development environment) leads to it trying to load client classes.

Caused by: java.lang.RuntimeException: Cannot load class me.shedaniel.rei.api.client.entry.renderer.EntryRenderer in environment type SERVER
        at net.fabricmc.loader.transformer.FabricTransformer.transform(FabricTransformer.java:75) ~[fabric-loader-0.11.3.jar:?]
        at net.fabricmc.loader.launch.knot.KnotClassDelegate.getPreMixinClassByteArray(KnotClassDelegate.java:185) ~[fabric-loader-0.11.3.jar:?]
        at net.fabricmc.loader.launch.knot.KnotClassDelegate.getPostMixinClassByteArray(KnotClassDelegate.java:152) ~[fabric-loader-0.11.3.jar:?]
        at net.fabricmc.loader.launch.knot.KnotClassLoader.loadClass(KnotClassLoader.java:150) ~[fabric-loader-0.11.3.jar:?]
        at java.lang.ClassLoader.loadClass(ClassLoader.java:519) ~[?:?]
        at java.lang.Class.forName0(Native Method) ~[?:?]
        at java.lang.Class.forName(Class.java:375) ~[?:?]
        at me.shedaniel.rei.RoughlyEnoughItemsInitializer.initializeEntryPoint(RoughlyEnoughItemsInitializer.java:56) ~[RoughlyEnoughItems-fabric-6.0.249-alpha.jar:?]
        at me.shedaniel.rei.RoughlyEnoughItemsInitializer.onInitialize(RoughlyEnoughItemsInitializer.java:39) ~[RoughlyEnoughItems-fabric-6.0.249-alpha.jar:?]
        at jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:?]
        at jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:78) ~[?:?]
        at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]
        at java.lang.reflect.Method.invoke(Method.java:567) ~[?:?]
        at net.fabricmc.loader.util.DefaultLanguageAdapter$1.invoke(DefaultLanguageAdapter.java:122) ~[fabric-loader-0.11.3.jar:?]

Sometimes it shows the FavoriteEntry class instead.

Steps to Reproduce

diff --git a/build.gradle b/build.gradle
old mode 100644
new mode 100755
index f807b77..bc0711f
--- a/build.gradle
+++ b/build.gradle
@@ -16,6 +16,7 @@ repositories {
        // Loom adds the essential maven repositories to download Minecraft and libraries from automatically.
        // See https://docs.gradle.org/current/userguide/declaring_repositories.html
        // for more information about repositories.
+     maven { url "https://maven.shedaniel.me/" }
 }

 dependencies {
@@ -26,6 +27,7 @@ dependencies {

        // Fabric API. This is technically optional, but you probably want it anyway.
        modImplementation "net.fabricmc.fabric-api:fabric-api:${project.fabric_version}"
+       modRuntime("me.shedaniel:RoughlyEnoughItems-fabric:6.0.249-alpha")

        // PSA: Some older mods, compiled on Loom 0.2.1, might have outdated Maven POMs.
        // You may need to force-disable transitiveness on them.

Type:
./gradlew runServer

commented

What was the fix, in which version was it released? We are seeing this now, but I can't tell if it's due to using an old version or not.

commented

@bendem your issue is likely a different issue, or reintroduced, as this is fixed last year, consider making a new issue.

commented

I also ran into this one when I moved from the laptop to the server

https://paste.ee/p/LWdbj

commented

Can confirm. Was just coming on here to post about it.

commented

Should be fixed.