GeyserMC / Floodgate

Hybrid mode plugin to allow for connections from Geyser to join online mode servers.
https://geysermc.org
MIT License
563 stars 168 forks source link

Unable to Enable/Load Floodgate - Paper 1.17 Experimental Build #160

Closed falceso closed 3 years ago

falceso commented 3 years ago

Description

In testing the latest experimental build provided by PaperMC Team for 1.17.

Geyser plugin appears to be loading in fine, however Floodgate reports the following error at startup. This error is not present in Spigot 1.17 (3145-Spigot-9472b09-f992ce6 (MC: 1.17)

Error occurred while enabling floodgate v2.0-SNAPSHOT (Is it up to date?)
java.lang.ExceptionInInitializerError: null
at org.geysermc.floodgate.inject.spigot.SpigotInjector.getServerConnection(SpigotInjector.java:160) ~[?:?]
at org.geysermc.floodgate.inject.spigot.SpigotInjector.inject(SpigotInjector.java:59) ~[?:?]
at org.geysermc.floodgate.FloodgatePlatform.enable(FloodgatePlatform.java:124) ~[?:?]
at org.geysermc.floodgate.SpigotPlatform.enable(SpigotPlatform.java:48) ~[?:?]
at org.geysermc.floodgate.SpigotPlugin.onEnable(SpigotPlugin.java:62) ~[?:?]
...

Full Error Log: https://gist.github.com/falceso/537b3b15617fef5ebbfda02960111529

To Reproduce

  1. Download the Experimental Paper 1.17 Build.
  2. Upload both the latest versions of Geyser and Floodgate.
  3. Start Server and see errors at startup.

Expected Behavior

Floodgate to operate normally similar to Spigot version.

Additional Information

PaperMC Issue/1.17 Experiment Build Download: https://github.com/PaperMC/Paper/issues/5785#issuecomment-862127357 Geyser Version: 1.4.0-SNAPSHOT Build 718 Floodgate Version: 2.0-SNAPSHOT Build 11

kennytv commented 3 years ago

Use Floodgate 2.0

Nixvip commented 3 years ago

Use Floodgate 2.0

[16:15:55] [Server thread/ERROR]: Error occurred while enabling floodgate v2.0-SNAPSHOT (Is it up to date?) java.lang.ExceptionInInitializerError: null at org.geysermc.floodgate.inject.spigot.SpigotInjector.getServerConnection(SpigotInjector.java:160) ~[?:?] at org.geysermc.floodgate.inject.spigot.SpigotInjector.inject(SpigotInjector.java:59) ~[?:?] at org.geysermc.floodgate.FloodgatePlatform.enable(FloodgatePlatform.java:124) ~[?:?] at org.geysermc.floodgate.SpigotPlatform.enable(SpigotPlatform.java:48) ~[?:?] at org.geysermc.floodgate.SpigotPlugin.onEnable(SpigotPlugin.java:62) ~[?:?] at org.bukkit.plugin.java.JavaPlugin.setEnabled(JavaPlugin.java:263) ~[patched_1.17.jar:git-Paper-"3740db0"] at org.bukkit.plugin.java.JavaPluginLoader.enablePlugin(JavaPluginLoader.java:370) ~[patched_1.17.jar:git-Paper-"3740db0"] at org.bukkit.plugin.SimplePluginManager.enablePlugin(SimplePluginManager.java:500) ~[patched_1.17.jar:git-Paper-"3740db0"] at org.bukkit.craftbukkit.v1_17_R1.CraftServer.enablePlugin(CraftServer.java:518) ~[patched_1.17.jar:git-Paper-"3740db0"] at org.bukkit.craftbukkit.v1_17_R1.CraftServer.enablePlugins(CraftServer.java:432) ~[patched_1.17.jar:git-Paper-"3740db0"] at net.minecraft.server.MinecraftServer.loadWorld(MinecraftServer.java:642) ~[patched_1.17.jar:git-Paper-"3740db0"] at net.minecraft.server.dedicated.DedicatedServer.init(DedicatedServer.java:303) ~[patched_1.17.jar:git-Paper-"3740db0"] at net.minecraft.server.MinecraftServer.x(MinecraftServer.java:1118) ~[patched_1.17.jar:git-Paper-"3740db0"] at net.minecraft.server.MinecraftServer.lambda$spin$0(MinecraftServer.java:319) ~[patched_1.17.jar:git-Paper-"3740db0"] at java.lang.Thread.run(Thread.java:831) [?:?] Caused by: java.lang.IllegalStateException: java.lang.ClassNotFoundException: net.minecraft.server.v1_17_R1.LoginListener$LoginHandler at org.geysermc.floodgate.util.ReflectionUtils.getClassOrThrow(ReflectionUtils.java:93) ~[?:?] at org.geysermc.floodgate.util.ClassNames.getClassOrFallBack(ClassNames.java:210) ~[?:?] at org.geysermc.floodgate.util.ClassNames.(ClassNames.java:180) ~[?:?] ... 15 more Caused by: java.lang.ClassNotFoundException: net.minecraft.server.v1_17_R1.LoginListener$LoginHandler at org.bukkit.plugin.java.PluginClassLoader.loadClass0(PluginClassLoader.java:157) ~[patched_1.17.jar:git-Paper-"3740db0"] at org.bukkit.plugin.java.PluginClassLoader.loadClass(PluginClassLoader.java:114) ~[patched_1.17.jar:git-Paper-"3740db0"] at java.lang.ClassLoader.loadClass(ClassLoader.java:519) ~[?:?] at java.lang.Class.forName0(Native Method) ~[?:?] at java.lang.Class.forName(Class.java:375) ~[?:?] at org.geysermc.floodgate.util.ReflectionUtils.getClassOrThrow(ReflectionUtils.java:91) ~[?:?] at org.geysermc.floodgate.util.ClassNames.getClassOrFallBack(ClassNames.java:210) ~[?:?] at org.geysermc.floodgate.util.ClassNames.(ClassNames.java:180) ~[?:?] ... 15 more [16:15:55] [Server thread/INFO]: [floodgate] Disabling floodgate v2.0-SNAPSHOT

Camotoy commented 3 years ago

Paper does not yet remap their internal Minecraft code from complete Mojmap to match Spigot's 1.17 handling (NMS), so this error is known and has to be fixed on Paper's end. Thank you anyway!

Camotoy commented 3 years ago

This should now be fixed on the latest commit of Paper 1.17. My explanation of why it was not working was incorrect - Paper did already remap to Spigot's form of NMS, but there was a bug in it handling a certain type of class.

Jaymin101 commented 11 months ago

I am getting the same error message for my 1.20.2 spigot server:

Error occurred while enabling floodgate v2.2.2-SNAPSHOT (b69-492be77) (Is it up to date?)

ha-rriz commented 11 months ago

Yeah same here

Tim203 commented 11 months ago

The issue you're describing is #448 which has been fixed in the latest build

DominusExult commented 4 months ago
Error occurred while enabling floodgate v2.2.2-SNAPSHOT (b97-58d71cb) (Is it up to date?)
mc-1        | java.lang.ExceptionInInitializerError: null
mc-1        | at floodgate-spigot.jar/org.geysermc.floodgate.inject.spigot.SpigotInjector.getServerConnection(SpigotInjector.java:173) ~[floodgate-spigot.jar:?]
mc-1        | at floodgate-spigot.jar/org.geysermc.floodgate.inject.spigot.SpigotInjector.inject(SpigotInjector.java:62) ~[floodgate-spigot.jar:?]
mc-1        | at floodgate-spigot.jar/org.geysermc.floodgate.FloodgatePlatform.enable(FloodgatePlatform.java:71) ~[floodgate-spigot.jar:?]
mc-1        | at floodgate-spigot.jar/org.geysermc.floodgate.SpigotPlugin.onEnable(SpigotPlugin.java:71) ~[floodgate-spigot.jar:?]
mc-1        | at org.bukkit.plugin.java.JavaPlugin.setEnabled(JavaPlugin.java:287) ~[paper-api-1.20.5-R0.1-SNAPSHOT.jar:?]
mc-1        | at io.papermc.paper.plugin.manager.PaperPluginInstanceManager.enablePlugin(PaperPluginInstanceManager.java:202) ~[paper-1.20.5.jar:git-Paper-10]
mc-1        | at io.papermc.paper.plugin.manager.PaperPluginManagerImpl.enablePlugin(PaperPluginManagerImpl.java:109) ~[paper-1.20.5.jar:git-Paper-10]
mc-1        | at org.bukkit.plugin.SimplePluginManager.enablePlugin(SimplePluginManager.java:519) ~[paper-api-1.20.5-R0.1-SNAPSHOT.jar:?]
mc-1        | at org.bukkit.craftbukkit.CraftServer.enablePlugin(CraftServer.java:639) ~[paper-1.20.5.jar:git-Paper-10]
mc-1        | at org.bukkit.craftbukkit.CraftServer.enablePlugins(CraftServer.java:551) ~[paper-1.20.5.jar:git-Paper-10]
mc-1        | at net.minecraft.server.MinecraftServer.loadWorld0(MinecraftServer.java:682) ~[paper-1.20.5.jar:git-Paper-10]
mc-1        | at net.minecraft.server.MinecraftServer.loadLevel(MinecraftServer.java:441) ~[paper-1.20.5.jar:git-Paper-10]
mc-1        | at net.minecraft.server.dedicated.DedicatedServer.initServer(DedicatedServer.java:324) ~[paper-1.20.5.jar:git-Paper-10]
mc-1        | at net.minecraft.server.MinecraftServer.runServer(MinecraftServer.java:1140) ~[paper-1.20.5.jar:git-Paper-10]
mc-1        | at net.minecraft.server.MinecraftServer.lambda$spin$0(MinecraftServer.java:326) ~[paper-1.20.5.jar:git-Paper-10]
mc-1        | at java.base/java.lang.Thread.run(Unknown Source) ~[?:?]
mc-1        | Caused by: java.lang.ArrayIndexOutOfBoundsException: Index 3 out of bounds for length 3
mc-1        | at floodgate-spigot.jar/org.geysermc.floodgate.util.ClassNames.<clinit>(ClassNames.java:97) ~[floodgate-spigot.jar:?]
mc-1        | ... 16 more
[floodgate] Disabling floodgate v2.2.2-SNAPSHOT (b97-58d71cb)

I guess this just means waiting for a new floodgate snapshot?

Tim203 commented 4 months ago

Note that ExceptionInInitializerError is a generic Floodgate error when something specific cannot be found (usually means that either Floodgate is outdated or doesn't yet support that specific server version), so future readers please check if there is an issue for your specific server version (and otherwise create an issue) and comment on there.