ProtocolLib

3M Downloads

[ERROR]: INTERNAL ERROR: Cannot compile structure. Disabling compiler.

h0ldhaven opened this issue ยท 3 comments

commented

Error description:
ProtocolLib cannot compile and show this error when player join the game.

Version Info:

  • git-Paper-576 (MC: 1.16.5)
  • ProtocolLib v4.6.1-SNAPSHOT-b498
  • Java SE Developpement Kit 16

Error in console:
[ProtocolLib-StructureCompiler 0/ERROR]: [ProtocolLib] INTERNAL ERROR: Cannot compile structure. Disabing compiler.
If this problem hasn't already been reported, please open a ticket
at https://github.com/dmulloy2/ProtocolLib/issues with the following data:
Stack Trace:
java.lang.reflect.InaccessibleObjectException: Unable to make protected final java.lang.Class java.lang.ClassLoader.defineClass(java.lang.String,byte[],int,int) throws java.lang.ClassFormatError accessible: module java.base does not "opens java.lang" to unnamed module @f4eb92d
at java.base/java.lang.reflect.AccessibleObject.checkCanSetAccessible(AccessibleObject.java:357)
at java.base/java.lang.reflect.AccessibleObject.checkCanSetAccessible(AccessibleObject.java:297)
at java.base/java.lang.reflect.Method.checkCanSetAccessible(Method.java:199)
at java.base/java.lang.reflect.Method.setAccessible(Method.java:193)
at com.comphenix.protocol.reflect.compiler.StructureCompiler.generateClass(StructureCompiler.java:299)
at com.comphenix.protocol.reflect.compiler.StructureCompiler.compile(StructureCompiler.java:213)
at com.comphenix.protocol.reflect.compiler.BackgroundCompiler$2.call(BackgroundCompiler.java:204)
at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1130)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:630)
at java.base/java.lang.Thread.run(Thread.java:831)
Dump:
Parameters:
com.comphenix.protocol.reflect.StructureModifier@3b01ba64[
targetType=class net.minecraft.server.v1_16_R3.PacketPlayInFlying$PacketPlayInPositionLook
target=
converter=
fieldType=class java.lang.Object
data=[public double net.minecraft.server.v1_16_R3.PacketPlayInFlying.x, public double net.minecraft.server.v1_16_R3.PacketPlayInFlying.y, public double net.minecraft.server.v1_16_R3.PacketPlayInFlying.z, public float net.minecraft.server.v1_16_R3.PacketPlayInFlying.yaw, public float net.minecraft.server.v1_16_R3.PacketPlayInFlying.pitch, protected boolean net.minecraft.server.v1_16_R3.PacketPlayInFlying.f, public boolean net.minecraft.server.v1_16_R3.PacketPlayInFlying.hasPos, public boolean net.minecraft.server.v1_16_R3.PacketPlayInFlying.hasLook]
defaultFields={}
subtypeCache={}
customConvertHandling=false
useStructureCompiler=true
]
manager:
com.comphenix.protocol.injector.PacketFilterManager@1fdbde47[
unhookTask=com.comphenix.protocol.injector.DelayedSingleTask@57f57f49
packetListeners=[com.bergerkiller.bukkit.common.internal.network.ProtocolLibPacketHandler$CommonPacketListener@331d680, PacketAdapter[plugin=HolographicDisplays, sending=ListeningWhitelist[priority=NORMAL, packets=[REL_ENTITY_MOVE_LOOK[class=PacketPlayOutRelEntityMoveLook, id=40], REL_ENTITY_MOVE[class=PacketPlayOutRelEntityMove, id=39], ENTITY_METADATA[class=PacketPlayOutEntityMetadata, id=68], SPAWN_ENTITY_LIVING[class=PacketPlayOutSpawnEntityLiving, id=2], SPAWN_ENTITY[class=PacketPlayOutSpawnEntity, id=0]], gamephase=PLAYING, options=[]], receiving=EMPTY_WHITELIST], com.bergerkiller.bukkit.common.internal.network.ProtocolLibPacketHandler$CommonPacketListener@4597c633, com.bergerkiller.bukkit.common.internal.network.ProtocolLibPacketHandler$CommonPacketMonitor@bf7b9b9]
packetInjector=com.comphenix.protocol.injector.netty.ProtocolInjector$5@20740e21
playerInjection=com.comphenix.protocol.injector.netty.ProtocolInjector$4@169042d1
inputBufferedPackets=[]
recievedListeners=com.comphenix.protocol.injector.SortedPacketListenerList@57f88fa2
sendingListeners=com.comphenix.protocol.injector.SortedPacketListenerList@2b0bbd23
hasClosed=false
classLoader=PluginClassLoader{plugin=ProtocolLib v4.6.1-SNAPSHOT-b498, pluginEnabled=true, url=plugins\ProtocolLib.jar}
reporter=com.comphenix.protocol.ProtocolLib$1@2b8eab65
server=CraftServer{serverName=Paper,serverVersion=git-Paper-576,minecraftVersion=1.16.5}
library=ProtocolLib v4.6.1-SNAPSHOT-b498
asyncFilterManager=com.comphenix.protocol.async.AsyncFilterManager@2c8aefc1
knowsServerPackets=true
knowsClientPackets=true
phaseLoginCount=0
phasePlayingCount=6
packetCreation=false
nettyInjector=com.comphenix.protocol.injector.netty.ProtocolInjector@274eeeca
pluginVerifier=com.comphenix.protocol.injector.PluginVerifier@89117e8
hasRecycleDistance=true
minecraftVersion=(MC: 1.16.5)
debug=false
]
Sender:
com.comphenix.protocol.reflect.compiler.BackgroundCompiler@23ace861[
listeners={com.comphenix.protocol.reflect.compiler.StructureCompiler$StructureKey@86265f90=[com.comphenix.protocol.injector.StructureCache$1@708d4826]}
listenerLock=java.lang.Object@2065c043
compiler=com.comphenix.protocol.reflect.compiler.StructureCompiler@204badf0
enabled=false
shuttingDown=false
executor=java.util.concurrent.Executors$FinalizableDelegatedExecutorService@6460b678
reporter=com.comphenix.protocol.ProtocolLib$1@2b8eab65
unknownPermGenBean=java.lang.Object@7eb60eaa
permGenBean=
disablePermGenFraction=0.65
]
Version:
ProtocolLib v4.6.1-SNAPSHOT-b498
Java Version:
16
Server:
git-Paper-576 (MC: 1.16.5)

commented

Have the same. Updated to Java 16 today for a plugin and got the same like h0ldhaven:

java.lang.reflect.InaccessibleObjectException: Unable to make protected final java.lang.Class java.lang.ClassLoader.defineClass(java.lang.String,byte[],int,int) throws java.lang.ClassFormatError accessible: module java.base does not "opens java.lang" to unnamed module @d436997
at java.base/java.lang.reflect.AccessibleObject.checkCanSetAccessible(AccessibleObject.java:357)
at java.base/java.lang.reflect.AccessibleObject.checkCanSetAccessible(AccessibleObject.java:297)
at java.base/java.lang.reflect.Method.checkCanSetAccessible(Method.java:199)
at java.base/java.lang.reflect.Method.setAccessible(Method.java:193)
at com.comphenix.protocol.reflect.compiler.StructureCompiler.generateClass(StructureCompiler.java:299)
at com.comphenix.protocol.reflect.compiler.StructureCompiler.compile(StructureCompiler.java:213)
at com.comphenix.protocol.reflect.compiler.BackgroundCompiler$2.call(BackgroundCompiler.java:204)
at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1130)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:630)
at java.base/java.lang.Thread.run(Thread.java:831)
Dump:
Parameters:
com.comphenix.protocol.reflect.StructureModifier@5454f917[
targetType=class net.minecraft.server.v1_16_R3.PacketPlayOutChat
target=
converter=
fieldType=class java.lang.Object
data=[private net.minecraft.server.v1_16_R3.IChatBaseComponent net.minecraft.server.v1_16_R3.PacketPlayOutChat.a, public net.md_5.bungee.api.chat.BaseComponent[] net.minecraft.server.v1_16_R3.PacketPlayOutChat.components, private net.minecraft.server.v1_16_R3.ChatMessageType net.minecraft.server.v1_16_R3.PacketPlayOutChat.b, private java.util.UUID net.minecraft.server.v1_16_R3.PacketPlayOutChat.c]
defaultFields={public net.md_5.bungee.api.chat.BaseComponent[] net.minecraft.server.v1_16_R3.PacketPlayOutChat.components=1, private net.minecraft.server.v1_16_R3.ChatMessageType net.minecraft.server.v1_16_R3.PacketPlayOutChat.b=2, private java.util.UUID net.minecraft.server.v1_16_R3.PacketPlayOutChat.c=3}
subtypeCache={class java.util.UUID=StructureModifier[fieldType=class java.util.UUID, data=[private java.util.UUID net.minecraft.server.v1_16_R3.PacketPlayOutChat.c]]}
customConvertHandling=false
useStructureCompiler=true
]
manager:
com.comphenix.protocol.injector.PacketFilterManager@2dea45bc[
unhookTask=com.comphenix.protocol.injector.DelayedSingleTask@6c992dda
packetListeners=[PacketAdapter[plugin=UltimateSigns, sending=ListeningWhitelist[priority=NORMAL, packets=[CHAT[class=PacketPlayOutChat, id=14]], gamephase=PLAYING, options=[]], receiving=EMPTY_WHITELIST], PacketAdapter[plugin=UltimateSigns, sending=EMPTY_WHITELIST, receiving=ListeningWhitelist[priority=NORMAL, packets=[UPDATE_SIGN[class=PacketPlayInUpdateSign, id=43]], gamephase=PLAYING, options=[]]], PacketAdapter[plugin=WorldGuardExtraFlags, sending=ListeningWhitelist[priority=NORMAL, packets=[REMOVE_ENTITY_EFFECT[class=PacketPlayOutRemoveEntityEffect, id=55]], gamephase=PLAYING, options=[]], receiving=EMPTY_WHITELIST]]
packetInjector=com.comphenix.protocol.injector.netty.ProtocolInjector$5@1ff6fd1f
playerInjection=com.comphenix.protocol.injector.netty.ProtocolInjector$4@2ddad360
inputBufferedPackets=[]
recievedListeners=com.comphenix.protocol.injector.SortedPacketListenerList@52e2b4c2
sendingListeners=com.comphenix.protocol.injector.SortedPacketListenerList@77b0a4b9
hasClosed=false
classLoader=org.bukkit.plugin.java.PluginClassLoader@6bf9f81e
reporter=com.comphenix.protocol.ProtocolLib$1@5f86b155
server=CraftServer{serverName=CraftBukkit,serverVersion=3028-Spigot-79d53c2-7eb3564,minecraftVersion=1.16.5}
library=ProtocolLib v4.6.0
asyncFilterManager=com.comphenix.protocol.async.AsyncFilterManager@63bfdcf7
knowsServerPackets=true
knowsClientPackets=true
phaseLoginCount=0
phasePlayingCount=4
packetCreation=true
nettyInjector=com.comphenix.protocol.injector.netty.ProtocolInjector@2342fe98
pluginVerifier=com.comphenix.protocol.injector.PluginVerifier@7380e924
hasRecycleDistance=true
minecraftVersion=(MC: 1.16.5)
debug=false
]
Sender:
com.comphenix.protocol.reflect.compiler.BackgroundCompiler@79451648[
listeners={com.comphenix.protocol.reflect.compiler.StructureCompiler$StructureKey@1e89f1b3=[com.comphenix.protocol.injector.StructureCache$1@79ec3db6], com.comphenix.protocol.reflect.compiler.StructureCompiler$StructureKey@4a0dfa62=[com.comphenix.protocol.reflect.compiler.BackgroundCompiler$1@4d6eaa2d]}
listenerLock=java.lang.Object@39d3b36d
compiler=com.comphenix.protocol.reflect.compiler.StructureCompiler@68750549
enabled=false
shuttingDown=false
executor=java.util.concurrent.Executors$FinalizableDelegatedExecutorService@70ec947c
reporter=com.comphenix.protocol.ProtocolLib$1@5f86b155
unknownPermGenBean=java.lang.Object@486b678e
permGenBean=
disablePermGenFraction=0.65
]
Version:
ProtocolLib v4.6.0
Java Version:
16
Server:
3028-Spigot-79d53c2-7eb3564 (MC: 1.16.5)

commented

hi, in MC1.15 "background compiler" is set to true by default, in 1.16.x this option causes this error, why?
is this due to a change in a java SE Development Kit update ?
EDIT: I disabled the "background compiler" in "config.yml" and have no more errors.

commented

Is it recommended to disable the "background compiler" in the config.yml of ProtocolLib?

When this option is disabled, the error no longer appears when the player joins the game and therefore seems to solve the problem if disabling this option has no impact on the use of the plugin. (the error occurs with the background compiler option If that can help you)