Holographic Displays

Holographic Displays

3M Downloads

onPacketSending(PacketEvent): Cannot retrieve entity from ID

badbones69 opened this issue ยท 19 comments

commented

I was testing out the 1.14 version of the plugin and got an error in console when I started my envoy. It doesn't seem to be coming from mine I do not believe so I'll just leave this error here for you. If it seems it's my plugin just let me know.

Error: https://pastebin.com/9Cm7V4Xm

My Plugin's code: https://github.com/badbones69/Crazy-Envoy/tree/0936c4bbde832444e7822b9a5a4aafb83539398f

My hook into HD: https://github.com/badbones69/Crazy-Envoy/blob/0936c4bbde832444e7822b9a5a4aafb83539398f/src/main/java/me/badbones69/crazyenvoy/multisupport/MVdWPlaceholderAPISupport.java

Build from Jenkins: https://ci.filoghost.me/job/HolographicDisplays/61/

commented

@badbones69 what's your ProtocolLib build number?

commented

Version: 4.4.0-b421

commented

if I have the same error and I can not activate server until it is solved I use the last protocollib etc .. exactly the same please solve this error thank you very much great work xD

commented

For the time being, it seems that you just to update ProtocolLib and keep up with the latest dev builds.

commented

I still have this problem in my plugin, did you manage to fix?

commented

filoghost's workaround, mentioned in his last comment, is probably the best solution for now. Hopefully there'll be a fix in protocollib soon though...

commented

Strange thing is that only sometimes this bug occurs.
After a server restart issue is vanished

commented

I'm receiving the same error with the latest HolographicDisplays build and the 'UltimateStacker' plugin: Spawner Holograms. Is this problem going to be solved?
Thanks in advance!

commented

I'm using the latest ProtocolLib-build available, but still receiving the error @filoghost. Is a Hologram-build for this problem going to be released? It seems that alot of Players are reporting this error on GITHub.

Thanks in advance!

commented

@MeesterMaarten can you please provide the updated error with the latest dev builds of both Holographic Displays and Protocol Lib?

commented

For anyone being redirected here from other duplicate issues, this is the correct link for Protocol Lib dev builds: http://ci.dmulloy2.net/job/ProtocolLib%20Gradle/

commented

Paper dev 122 (Spigot 1.14.3)
HolographicDisplay dev 84 (commit: be96a5c)
ProtocolLib Gradle dev 9
Citizens2 dev 1717

@filoghost I'm also receiving this error as well with the latest dev builds of both ProtocolLib and HolographicDisplay.

[13:01:43] [Server thread/ERROR]: [HolographicDisplays] Unhandled exception occured in onPacketSending(PacketEvent) for HolographicDisplays
java.lang.RuntimeException: Cannot retrieve entity from ID.
	at com.comphenix.protocol.wrappers.BukkitConverters$9.getSpecific(BukkitConverters.java:648) ~[?:?]
	at com.comphenix.protocol.wrappers.BukkitConverters$9.getSpecific(BukkitConverters.java:627) ~[?:?]
	at com.comphenix.protocol.reflect.StructureModifier.readInternal(StructureModifier.java:227) ~[?:?]
	at com.comphenix.protocol.reflect.StructureModifier.read(StructureModifier.java:195) ~[?:?]
	at com.gmail.filoghost.holographicdisplays.bridge.protocollib.current.packet.WrapperPlayServerSpawnEntityLiving.getEntity(WrapperPlayServerSpawnEntityLiving.java:70) ~[?:?]
	at com.gmail.filoghost.holographicdisplays.bridge.protocollib.current.packet.WrapperPlayServerSpawnEntityLiving.getEntity(WrapperPlayServerSpawnEntityLiving.java:79) ~[?:?]
	at com.gmail.filoghost.holographicdisplays.bridge.protocollib.current.ProtocolLibHookImpl$1.onPacketSending(ProtocolLibHookImpl.java:134) ~[?:?]
	at com.comphenix.protocol.injector.SortedPacketListenerList.invokeSendingListener(SortedPacketListenerList.java:195) ~[?:?]
	at com.comphenix.protocol.injector.SortedPacketListenerList.invokePacketSending(SortedPacketListenerList.java:149) ~[?:?]
	at com.comphenix.protocol.injector.PacketFilterManager.handlePacket(PacketFilterManager.java:588) ~[?:?]
	at com.comphenix.protocol.injector.PacketFilterManager.invokePacketSending(PacketFilterManager.java:564) ~[?:?]
	at com.comphenix.protocol.injector.netty.ProtocolInjector.packetQueued(ProtocolInjector.java:338) ~[?:?]
	at com.comphenix.protocol.injector.netty.ProtocolInjector.onPacketSending(ProtocolInjector.java:298) ~[?:?]
	at com.comphenix.protocol.injector.netty.ChannelInjector.processSending(ChannelInjector.java:364) ~[?:?]
	at com.comphenix.protocol.injector.netty.ChannelInjector.access$800(ChannelInjector.java:63) ~[?:?]
	at com.comphenix.protocol.injector.netty.ChannelInjector$3.handleScheduled(ChannelInjector.java:329) ~[?:?]
	at com.comphenix.protocol.injector.netty.ChannelInjector$3.onMessageScheduled(ChannelInjector.java:299) ~[?:?]
	at com.comphenix.protocol.injector.netty.ChannelProxy$2.schedulingRunnable(ChannelProxy.java:127) ~[?:?]
	at com.comphenix.protocol.injector.netty.EventLoopProxy.execute(EventLoopProxy.java:95) ~[?:?]
	at net.minecraft.server.v1_14_R1.NetworkManager.b(NetworkManager.java:208) ~[patched_1.14.3.jar:git-Paper-122]
	at net.minecraft.server.v1_14_R1.NetworkManager.sendPacket(NetworkManager.java:171) ~[patched_1.14.3.jar:git-Paper-122]
	at net.minecraft.server.v1_14_R1.PlayerConnection.a(PlayerConnection.java:1552) ~[patched_1.14.3.jar:git-Paper-122]
	at net.minecraft.server.v1_14_R1.PlayerConnection.sendPacket(PlayerConnection.java:1525) ~[patched_1.14.3.jar:git-Paper-122]
	at protocolsupport.zplatform.impl.spigot.entitytracker.SpigotEntityTrackerEntry.a(SpigotEntityTrackerEntry.java:199) ~[?:?]
	at protocolsupport.zplatform.impl.spigot.entitytracker.SpigotEntityTrackerEntry.b(SpigotEntityTrackerEntry.java:189) ~[?:?]
	at net.minecraft.server.v1_14_R1.PlayerChunkMap$EntityTracker.updatePlayer(PlayerChunkMap.java:1269) ~[patched_1.14.3.jar:git-Paper-122]
	at net.minecraft.server.v1_14_R1.PlayerChunkMap.a(PlayerChunkMap.java:1129) ~[patched_1.14.3.jar:git-Paper-122]
	at net.minecraft.server.v1_14_R1.PlayerChunkMap.sendChunk(PlayerChunkMap.java:780) ~[patched_1.14.3.jar:git-Paper-122]
	at net.minecraft.server.v1_14_R1.PlayerChunkMap.a(PlayerChunkMap.java:882) ~[patched_1.14.3.jar:git-Paper-122]
	at net.minecraft.server.v1_14_R1.PlayerChunkMap.addEntity(PlayerChunkMap.java:1017) ~[patched_1.14.3.jar:git-Paper-122]
	at net.minecraft.server.v1_14_R1.ChunkProviderServer.addEntity(ChunkProviderServer.java:536) ~[patched_1.14.3.jar:git-Paper-122]
	at net.minecraft.server.v1_14_R1.WorldServer.registerEntity(WorldServer.java:1154) ~[patched_1.14.3.jar:git-Paper-122]
	at net.minecraft.server.v1_14_R1.WorldServer.addPlayer0(WorldServer.java:943) ~[patched_1.14.3.jar:git-Paper-122]
	at net.minecraft.server.v1_14_R1.WorldServer.addPlayerJoin(WorldServer.java:919) ~[patched_1.14.3.jar:git-Paper-122]
	at net.minecraft.server.v1_14_R1.PlayerList.a(PlayerList.java:229) ~[patched_1.14.3.jar:git-Paper-122]
	at protocolsupport.zplatform.impl.spigot.network.handler.SpigotLoginListenerPlay.joinGame(SpigotLoginListenerPlay.java:137) ~[?:?]
	at protocolsupport.protocol.packet.handler.AbstractLoginListenerPlay.tryJoin(AbstractLoginListenerPlay.java:139) ~[?:?]
	at protocolsupport.protocol.packet.handler.AbstractLoginListenerPlay.loginTick(AbstractLoginListenerPlay.java:100) ~[?:?]
	at protocolsupport.protocol.packet.handler.AbstractLoginListenerPlay$1.run(AbstractLoginListenerPlay.java:43) ~[?:?]
	at org.bukkit.craftbukkit.v1_14_R1.scheduler.CraftTask.run(CraftTask.java:84) ~[patched_1.14.3.jar:git-Paper-122]
	at org.bukkit.craftbukkit.v1_14_R1.scheduler.CraftScheduler.mainThreadHeartbeat(CraftScheduler.java:452) ~[patched_1.14.3.jar:git-Paper-122]
	at net.minecraft.server.v1_14_R1.MinecraftServer.b(MinecraftServer.java:1132) ~[patched_1.14.3.jar:git-Paper-122]
	at net.minecraft.server.v1_14_R1.DedicatedServer.b(DedicatedServer.java:420) ~[patched_1.14.3.jar:git-Paper-122]
	at net.minecraft.server.v1_14_R1.MinecraftServer.a(MinecraftServer.java:1064) ~[patched_1.14.3.jar:git-Paper-122]
	at net.minecraft.server.v1_14_R1.MinecraftServer.run(MinecraftServer.java:908) ~[patched_1.14.3.jar:git-Paper-122]
	at java.lang.Thread.run(Thread.java:748) [?:1.8.0_212]
Caused by: com.comphenix.protocol.reflect.FieldAccessException: Cannot find entity from ID 480.
	at com.comphenix.protocol.injector.EntityUtilities.getEntityFromID(EntityUtilities.java:222) ~[?:?]
	at com.comphenix.protocol.injector.PacketFilterManager.getEntityFromID(PacketFilterManager.java:932) ~[?:?]
	at com.comphenix.protocol.wrappers.BukkitConverters$9.getSpecific(BukkitConverters.java:642) ~[?:?]
	... 45 more
Caused by: java.lang.RuntimeException: Cannot read  private final net.minecraft.server.v1_14_R1.Entity net.citizensnpcs.nms.v1_14_R1.util.PlayerlistTracker.tracker
	at com.comphenix.protocol.reflect.accessors.DefaultFieldAccessor.get(DefaultFieldAccessor.java:17) ~[?:?]
	at com.comphenix.protocol.injector.EntityUtilities.getEntityFromID(EntityUtilities.java:216) ~[?:?]
	at com.comphenix.protocol.injector.PacketFilterManager.getEntityFromID(PacketFilterManager.java:932) ~[?:?]
	at com.comphenix.protocol.wrappers.BukkitConverters$9.getSpecific(BukkitConverters.java:642) ~[?:?]
	... 45 more
Caused by: java.lang.IllegalArgumentException: Can not set final net.minecraft.server.v1_14_R1.Entity field net.citizensnpcs.nms.v1_14_R1.util.PlayerlistTracker.tracker to net.minecraft.server.v1_14_R1.PlayerChunkMap$EntityTracker
	at sun.reflect.UnsafeFieldAccessorImpl.throwSetIllegalArgumentException(UnsafeFieldAccessorImpl.java:167) ~[?:1.8.0_212]
	at sun.reflect.UnsafeFieldAccessorImpl.throwSetIllegalArgumentException(UnsafeFieldAccessorImpl.java:171) ~[?:1.8.0_212]
	at sun.reflect.UnsafeFieldAccessorImpl.ensureObj(UnsafeFieldAccessorImpl.java:58) ~[?:1.8.0_212]
	at sun.reflect.UnsafeQualifiedObjectFieldAccessorImpl.get(UnsafeQualifiedObjectFieldAccessorImpl.java:38) ~[?:1.8.0_212]
	at java.lang.reflect.Field.get(Field.java:393) ~[?:1.8.0_212]
	at com.comphenix.protocol.reflect.accessors.DefaultFieldAccessor.get(DefaultFieldAccessor.java:15) ~[?:?]
	at com.comphenix.protocol.injector.EntityUtilities.getEntityFromID(EntityUtilities.java:216) ~[?:?]
	at com.comphenix.protocol.injector.PacketFilterManager.getEntityFromID(PacketFilterManager.java:932) ~[?:?]
	at com.comphenix.protocol.wrappers.BukkitConverters$9.getSpecific(BukkitConverters.java:642) ~[?:?]
	... 45 more
[13:01:43] [Server thread/ERROR]: Parameters: 
  net.minecraft.server.v1_14_R1.PacketPlayOutSpawnEntityLiving@11237678[
    a=480
    b=c87d9fbc-d313-4d4d-946f-7bd5c31ab5e2
    c=1
    d=-138.227
    e=127.841
    f=-787.985
    g=0
    h=0
    i=0
    j=0
    k=0
    l=0
    m=net.minecraft.server.v1_14_R1.DataWatcher@7c0b2b03
    n=<null>
  ]

commented

@mibby It's still caused by Citizens, I will check if I need to manually exclude their entities or they're fixing it.

commented

References: CitizensDev/Citizens2#1858

I'm getting the same issue. A very quick check of the Citizens codebase seems to indicate that the real error is that the field net.citizensnpcs.nms.v1_14_R1.util.PlayerlistTracker#tracker is being set to something that is not assignable. The relevant line from the sun reflect code (because the actual thrown error is misleading) is:

https://github.com/frohoff/jdk8u-jdk/blob/master/src/share/classes/sun/reflect/UnsafeFieldAccessorImpl.java#L58

    protected void ensureObj(Object o) {
        // NOTE: will throw NullPointerException, as specified, if o is null
        if (!field.getDeclaringClass().isAssignableFrom(o.getClass())) {
            throwSetIllegalArgumentException(o);
        }
    }

A dump of my exception is:

07:11:24 [INFO] [paper-1.14] [07:11:24 ERROR]: [HolographicDisplays] Unhandled exception occured in onPacketSending(PacketEvent) for HolographicDisplays
07:11:24 [INFO] [paper-1.14] java.lang.RuntimeException: Cannot retrieve entity from ID.
07:11:24 [INFO] [paper-1.14]     at com.comphenix.protocol.wrappers.BukkitConverters$9.getSpecific(BukkitConverters.java:648) ~[?:?]
07:11:24 [INFO] [paper-1.14]     at com.comphenix.protocol.wrappers.BukkitConverters$9.getSpecific(BukkitConverters.java:627) ~[?:?]
07:11:24 [INFO] [paper-1.14]     at com.comphenix.protocol.reflect.StructureModifier.readInternal(StructureModifier.java:227) ~[?:?]
07:11:24 [INFO] [paper-1.14]     at com.comphenix.protocol.reflect.StructureModifier.read(StructureModifier.java:195) ~[?:?]
07:11:24 [INFO] [paper-1.14]     at com.gmail.filoghost.holographicdisplays.bridge.protocollib.current.packet.WrapperPlayServerEntityMetadata.getEntity(WrapperPlayServerEnt
ityMetadata.java:65) ~[?:?]
07:11:24 [INFO] [paper-1.14]     at com.gmail.filoghost.holographicdisplays.bridge.protocollib.current.packet.WrapperPlayServerEntityMetadata.getEntity(WrapperPlayServerEntityMetadata.java:74) ~[?:?]
07:11:24 [INFO] [paper-1.14]     at com.gmail.filoghost.holographicdisplays.bridge.protocollib.current.ProtocolLibHookImpl$1.onPacketSending(ProtocolLibHookImpl.java:173) ~[?:?]
07:11:24 [INFO] [paper-1.14]     at com.comphenix.protocol.injector.SortedPacketListenerList.invokeSendingListener(SortedPacketListenerList.java:195) ~[?:?]
07:11:24 [INFO] [paper-1.14]     at com.comphenix.protocol.injector.SortedPacketListenerList.invokePacketSending(SortedPacketListenerList.java:149) ~[?:?]
07:11:24 [INFO] [paper-1.14]     at com.comphenix.protocol.injector.PacketFilterManager.handlePacket(PacketFilterManager.java:588) ~[?:?]
07:11:24 [INFO] [paper-1.14]     at com.comphenix.protocol.injector.PacketFilterManager.invokePacketSending(PacketFilterManager.java:564) ~[?:?]
07:11:24 [INFO] [paper-1.14]     at com.comphenix.protocol.injector.netty.ProtocolInjector.packetQueued(ProtocolInjector.java:338) ~[?:?]
07:11:24 [INFO] [paper-1.14]     at com.comphenix.protocol.injector.netty.ProtocolInjector.onPacketSending(ProtocolInjector.java:298) ~[?:?]
07:11:24 [INFO] [paper-1.14]     at com.comphenix.protocol.injector.netty.ChannelInjector.processSending(ChannelInjector.java:364) ~[?:?]
07:11:24 [INFO] [paper-1.14]     at com.comphenix.protocol.injector.netty.ChannelInjector.access$800(ChannelInjector.java:63) ~[?:?]
07:11:24 [INFO] [paper-1.14]     at com.comphenix.protocol.injector.netty.ChannelInjector$3.handleScheduled(ChannelInjector.java:329) ~[?:?]
07:11:24 [INFO] [paper-1.14]     at com.comphenix.protocol.injector.netty.ChannelInjector$3.onMessageScheduled(ChannelInjector.java:299) ~[?:?]
07:11:24 [INFO] [paper-1.14]     at com.comphenix.protocol.injector.netty.ChannelProxy$2.schedulingRunnable(ChannelProxy.java:127) ~[?:?]
07:11:24 [INFO] [paper-1.14]     at com.comphenix.protocol.injector.netty.EventLoopProxy.execute(EventLoopProxy.java:95) ~[?:?]
07:11:24 [INFO] [paper-1.14]     at net.minecraft.server.v1_14_R1.NetworkManager.b(NetworkManager.java:208) ~[patched_1.14.3.jar:git-Paper-129]
07:11:24 [INFO] [paper-1.14]     at net.minecraft.server.v1_14_R1.NetworkManager.sendPacket(NetworkManager.java:171) ~[patched_1.14.3.jar:git-Paper-129]
07:11:24 [INFO] [paper-1.14]     at net.minecraft.server.v1_14_R1.PlayerConnection.a(PlayerConnection.java:1552) ~[patched_1.14.3.jar:git-Paper-129]
07:11:24 [INFO] [paper-1.14]     at net.minecraft.server.v1_14_R1.PlayerConnection.sendPacket(PlayerConnection.java:1525) ~[patched_1.14.3.jar:git-Paper-129]
07:11:24 [INFO] [paper-1.14]     at net.minecraft.server.v1_14_R1.EntityTrackerEntry.broadcastIncludingSelf(EntityTrackerEntry.java:391) ~[patched_1.14.3.jar:git-Paper-129]
07:11:24 [INFO] [paper-1.14]     at net.minecraft.server.v1_14_R1.EntityTrackerEntry.c(EntityTrackerEntry.java:351) ~[patched_1.14.3.jar:git-Paper-129]
07:11:24 [INFO] [paper-1.14]     at net.minecraft.server.v1_14_R1.EntityTrackerEntry.a(EntityTrackerEntry.java:199) ~[patched_1.14.3.jar:git-Paper-129]
07:11:24 [INFO] [paper-1.14]     at net.minecraft.server.v1_14_R1.PlayerChunkMap.g(PlayerChunkMap.java:1070) ~[patched_1.14.3.jar:git-Paper-129]
07:11:24 [INFO] [paper-1.14]     at net.minecraft.server.v1_14_R1.ChunkProviderServer.tickChunks(ChunkProviderServer.java:476) ~[patched_1.14.3.jar:git-Paper-129]
07:11:24 [INFO] [paper-1.14]     at net.minecraft.server.v1_14_R1.ChunkProviderServer.tick(ChunkProviderServer.java:370) ~[patched_1.14.3.jar:git-Paper-129]
07:11:24 [INFO] [paper-1.14]     at net.minecraft.server.v1_14_R1.WorldServer.doTick(WorldServer.java:264) ~[patched_1.14.3.jar:git-Paper-129]
07:11:24 [INFO] [paper-1.14]     at net.minecraft.server.v1_14_R1.MinecraftServer.b(MinecraftServer.java:1192) ~[patched_1.14.3.jar:git-Paper-129]
07:11:24 [INFO] [paper-1.14]     at net.minecraft.server.v1_14_R1.DedicatedServer.b(DedicatedServer.java:420) ~[patched_1.14.3.jar:git-Paper-129]
07:11:24 [INFO] [paper-1.14]     at net.minecraft.server.v1_14_R1.MinecraftServer.a(MinecraftServer.java:1064) ~[patched_1.14.3.jar:git-Paper-129]
07:11:24 [INFO] [paper-1.14]     at net.minecraft.server.v1_14_R1.MinecraftServer.run(MinecraftServer.java:908) ~[patched_1.14.3.jar:git-Paper-129]
07:11:24 [INFO] [paper-1.14]     at java.lang.Thread.run(Thread.java:748) [?:1.8.0_171]
07:11:24 [INFO] [paper-1.14] Caused by: com.comphenix.protocol.reflect.FieldAccessException: Cannot find entity from ID 27.
07:11:24 [INFO] [paper-1.14]     at com.comphenix.protocol.injector.EntityUtilities.getEntityFromID(EntityUtilities.java:222) ~[?:?]
07:11:24 [INFO] [paper-1.14]     at com.comphenix.protocol.injector.PacketFilterManager.getEntityFromID(PacketFilterManager.java:932) ~[?:?]
07:11:24 [INFO] [paper-1.14]     at com.comphenix.protocol.wrappers.BukkitConverters$9.getSpecific(BukkitConverters.java:642) ~[?:?]
07:11:24 [INFO] [paper-1.14]     ... 34 more
07:11:24 [INFO] [paper-1.14] Caused by: java.lang.RuntimeException: Cannot read  private final net.minecraft.server.v1_14_R1.Entity net.citizensnpcs.nms.v1_14_R1.util.PlayerlistTracker.tracker
07:11:24 [INFO] [paper-1.14]     at com.comphenix.protocol.reflect.accessors.DefaultFieldAccessor.get(DefaultFieldAccessor.java:17) ~[?:?]
07:11:24 [INFO] [paper-1.14]     at com.comphenix.protocol.injector.EntityUtilities.getEntityFromID(EntityUtilities.java:216) ~[?:?]
07:11:24 [INFO] [paper-1.14]     at com.comphenix.protocol.injector.PacketFilterManager.getEntityFromID(PacketFilterManager.java:932) ~[?:?]
07:11:24 [INFO] [paper-1.14]     at com.comphenix.protocol.wrappers.BukkitConverters$9.getSpecific(BukkitConverters.java:642) ~[?:?]
07:11:24 [INFO] [paper-1.14]     ... 34 more
07:11:24 [INFO] [paper-1.14] Caused by: java.lang.IllegalArgumentException: Can not set final net.minecraft.server.v1_14_R1.Entity field net.citizensnpcs.nms.v1_14_R1.util.PlayerlistTracker.tracker to net.minecraft.server.v1_14_R1.PlayerChunkMap$EntityTracker
07:11:24 [INFO] [paper-1.14]     at sun.reflect.UnsafeFieldAccessorImpl.throwSetIllegalArgumentException(UnsafeFieldAccessorImpl.java:167) ~[?:1.8.0_171]
07:11:24 [INFO] [paper-1.14]     at sun.reflect.UnsafeFieldAccessorImpl.throwSetIllegalArgumentException(UnsafeFieldAccessorImpl.java:171) ~[?:1.8.0_171]
07:11:24 [INFO] [paper-1.14]     at sun.reflect.UnsafeFieldAccessorImpl.ensureObj(UnsafeFieldAccessorImpl.java:58) ~[?:1.8.0_171]
07:11:24 [INFO] [paper-1.14]     at sun.reflect.UnsafeQualifiedObjectFieldAccessorImpl.get(UnsafeQualifiedObjectFieldAccessorImpl.java:38) ~[?:1.8.0_171]
07:11:24 [INFO] [paper-1.14]     at java.lang.reflect.Field.get(Field.java:393) ~[?:1.8.0_171]
07:11:24 [INFO] [paper-1.14]     at com.comphenix.protocol.reflect.accessors.DefaultFieldAccessor.get(DefaultFieldAccessor.java:15) ~[?:?]
07:11:24 [INFO] [paper-1.14]     at com.comphenix.protocol.injector.EntityUtilities.getEntityFromID(EntityUtilities.java:216) ~[?:?]
07:11:24 [INFO] [paper-1.14]     at com.comphenix.protocol.injector.PacketFilterManager.getEntityFromID(PacketFilterManager.java:932) ~[?:?]
07:11:24 [INFO] [paper-1.14]     at com.comphenix.protocol.wrappers.BukkitConverters$9.getSpecific(BukkitConverters.java:642) ~[?:?]
07:11:24 [INFO] [paper-1.14]     ... 34 more
07:11:24 [INFO] [paper-1.14] [07:11:24 ERROR]: Parameters:
07:11:24 [INFO] [paper-1.14]   net.minecraft.server.v1_14_R1.PacketPlayOutEntityMetadata@35607c30[
07:11:24 [INFO] [paper-1.14]     a=27
07:11:24 [INFO] [paper-1.14]     b=[net.minecraft.server.v1_14_R1.DataWatcher$Item@78b82462]
07:11:24 [INFO] [paper-1.14]   ]

My plugins:

shared/plugins/1.14$ ls -al | tr -s " " | cut -d " " -f 9- | grep -v ^\\.

ActionHealth.jar -> ../all/ActionHealth-3.3.0.jar
BetonQuest.jar -> ../all/BetonQuest.jar
citizens.jar -> ../all/Citizens-2.0.25-b1721.jar
CoreProtect.jar -> ../all/CoreProtect-2.17.4.jar
dynmap.jar -> ../all/Dynmap-3.0-SNAPSHOT-spigot.jar
EffectLib.jar -> ../all/EffectLib-6.1.jar
FastLoginBukkit.jar -> ../all/FastLoginBukkit-build885.jar
Harbor.jar -> ../all/Harbor-1.5.jar
HeadsPlus.jar -> ../all/HeadsPlus-6.3.1.jar
Holograms.jar -> ../all/Holograms-2.7.jar
HolographicDisplays.jar -> ../all/HolographicDisplays-2.3.3-SNAPSHOT-b84.jar
LuckPerms-Bukkit.jar -> ../all/LuckPerms-Bukkit-4.4.25.jar
MySkin.jar -> ../all/MySkin-2.7.jar
NPCDestinations.jar -> ../all/NPCDestinations-Plugin-2.3.0-snapshot.jar
PlaceholderAPI.jar -> ../all/PlaceholderAPI-2.10.2.jar
ProtocolLib.jar -> ../all/ProtocolLib-b9.jar
UltimateChat.jar -> ../all/UltimateChat-1.8.9-b224-Universal.jar
Vault.jar -> ../all/Vault-1.7.2.jar
worldedit.jar -> ../all/worldedit-bukkit-7.0.0-SNAPSHOT-20190528.jar
WorldGuardExtraFlags.jar -> ../all/WorldGuardExtraFlags-4.1.2.jar
worldguard-legacy.jar -> ../all/worldguard-legacy-7.0.0-SNAPSHOT-20190528.jar
WorldResourcepacks.jar -> ../all/WorldResourcepacks-271.jar
commented

The relevant code in Citizens:
https://github.com/CitizensDev/Citizens2/blob/master/v1_14_R1/src/main/java/net/citizensnpcs/nms/v1_14_R1/util/PlayerlistTracker.java#L21

public class PlayerlistTracker extends PlayerChunkMap.EntityTracker {
    private final PlayerChunkMap map;
    private final Entity tracker;

The overridden code in NMS:

    public class EntityTracker {
        private final EntityTrackerEntry trackerEntry;
        private final Entity tracker;

Code in ProtocolLib that threw the exception:
https://github.com/dmulloy2/ProtocolLib/blob/gradle/src/main/java/com/comphenix/protocol/injector/EntityUtilities.java#L200-L216

trackerField = Accessors.getFieldAccessor(trackerEntry.getClass(), "tracker", true);
// ...
tracker = trackerField.get(trackerEntry); // Exception here

Which tracks from there into here: https://github.com/dmulloy2/ProtocolLib/blob/gradle/src/main/java/com/comphenix/protocol/reflect/accessors/DefaultFieldAccessor.java#L15

I'm not completely sure about this, but I think trackerField got set to the Citizens class's field (by way of the first tracker being passed into it being one generated by Citizens), and is then being used to read against vanilla instances of the class (which are of course incompatible with that reflection lookup). The solution would be to replace trackerEntry.getClass() in the linked ProtocolLib code with PlayerChunkMap.EntityTracker.class or an equivalent value like a Class.forName call (ie: explicitly use the class it's meant to work with, rather than trying to dynamically hack it).

This would place the issue resolution into ProtocolLib's code so I'll cc @dmulloy2

commented

It looks like trackerEntry is assigned differently with 1.14 than below. My guess is the actual fault lies somewhere in here. Just noting so I can look at it in a bit.

https://github.com/dmulloy2/ProtocolLib/blob/gradle/src/main/java/com/comphenix/protocol/injector/EntityUtilities.java#L136-L163

commented

@filoghost Any possible update or workaround following @mcmonkey4eva's response? :(

Still occurring for me.
https://paste.ubuntu.com/p/KyVpdxcTDq/

Paper dev 153 (Spigot 1.14.4)
ProtocolLib-Gradle dev 9
HolographicDisplays dev 85
Citizens dev 1737

commented

I tried to develop a workaround (ffb8680) for both of these bugs (the one already fixed in newer ProtocolLib versions, and the one related to Citizens). Try the latest dev build: https://ci.codemc.org/job/filoghost/job/HolographicDisplays

I was not able to reproduce the bug with Citizens, please let me know if it's fixed or not.

The bug still has to be fixed in ProtocolLib.

commented

@filoghost Yes, the latest build fixes it