Calling getPlayerInfoDataList().write with Collections.singletonList causes NoClassDefFoundException on 1.17.1
Andre601 opened this issue ยท 1 comments
Describe the bug
Currently using the plugin AdvancedTabOverlay which relies on ProtocolLib to function.
Now when I start the server is the following Exception printed by ATO and the plugin breaks: https://paste.helpch.at/ufufixugox.md
Checking the code of ATO doesn't really show anything unusual/unsupported here, unless a singletonList is for some reason not supported here.
Code used:
https://github.com/CodeCrafter47/AdvancedTabOverlay/blob/dev/src/main/java/de/codecrafter47/taboverlay/bukkit/internal/handler/safe/PacketHelper1_17.java#L208
The error itself points to Constructor<?> ctor = listClass.getConstructor();
of the BukkitConverters class and seems to be similar to, if not even the same as #1331 so my assumption that singleton lists aren't supported seems valid here.
To Reproduce
Steps to reproduce the behavior:
- Create a packet using
ProtocolLibrary.getProtocolManager().createPacket(PacketType.Play.Server.PLAYER_INFO)
- Write to the packet using
getPlayerInfoDataList().write(...)
See this line for full code used. - You should see the error
Expected behavior
ProtocolLib should support this action.
In fact DID the plugin support this previously but now doesn't for unknown reasons. The code of the other plugin (ATO) did not change in that matter.
Screenshots
Version Info
dump-2021-09-26_15.41.09.txt
Additional context
I'm aware that this can be an issue on ATO's end, but looking at the code and the fact that this code hasn't been changed frequently, do I assume that it's more an internal change in ProtocolLib that causes this incompatibility.
If it matters is here a full list of all currently running plugins on my server:
AdvancedTabOverlay, AdvanceParticle, ArmorStandTools, BKCommonLib, CinematicUI, Citizens, Essentials, EssentialsChat, InfoHeads, InteractiveBoard, ItemsAdder, LoneLibs, LuckPerms, Maplands, MiniMOTD, PlaceholderAPI, ProtocolLib, QuickShop, ResourcePackBroadcast, TCCoasters, Train_Carts, Vault
In addition is following Java version used:
openjdk version "16.0.1" 2021-04-20
OpenJDK Runtime Environment AdoptOpenJDK-16.0.1+9 (build 16.0.1+9)
OpenJDK 64-Bit Server VM AdoptOpenJDK-16.0.1+9 (build 16.0.1+9, mixed mode, sharing)