Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GsonComponentSerializerExtended's failure #666

Closed
BlackBaroness opened this issue Jan 24, 2024 · 8 comments · Fixed by #672
Closed

GsonComponentSerializerExtended's failure #666

BlackBaroness opened this issue Jan 24, 2024 · 8 comments · Fixed by #672
Labels
bug Something isn't working

Comments

@BlackBaroness
Copy link

Describe the bug
WrapperPlayServerSystemChatMessage can't deserialize a component:

[09:38:06 WARN] [com.github.retrooper.packetevents.PacketEventsAPI]: PacketEvents caught an unhandled exception while calling your listener.
com.google.gson.JsonIOException: Interfaces can't be instantiated! Register an InstanceCreator or a TypeAdapter for this type. Interface name: net.kyori.adventure.text.TranslationArgument
        at com.google.gson.internal.ConstructorConstructor$3.construct(ConstructorConstructor.java:136) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory$FieldReflectionAdapter.createAccumulator(ReflectiveTypeAdapterFactory.java:427) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory$Adapter.read(ReflectiveTypeAdapterFactory.java:383) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at com.google.gson.internal.bind.TypeAdapterRuntimeTypeWrapper.read(TypeAdapterRuntimeTypeWrapper.java:40) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at com.google.gson.internal.bind.CollectionTypeAdapterFactory$Adapter.read(CollectionTypeAdapterFactory.java:82) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at com.google.gson.internal.bind.CollectionTypeAdapterFactory$Adapter.read(CollectionTypeAdapterFactory.java:61) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at com.google.gson.Gson.fromJson(Gson.java:1227) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at com.google.gson.Gson.fromJson(Gson.java:1186) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at net.kyori.adventure.text.serializer.gson.ComponentSerializerImpl.read(ComponentSerializerImpl.java:149) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at net.kyori.adventure.text.serializer.gson.ComponentSerializerImpl.read(ComponentSerializerImpl.java:77) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at com.google.gson.TypeAdapter$1.read(TypeAdapter.java:204) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at com.google.gson.Gson.fromJson(Gson.java:1227) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at com.google.gson.Gson.fromJson(Gson.java:1137) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at com.google.gson.Gson.fromJson(Gson.java:1047) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at com.google.gson.Gson.fromJson(Gson.java:982) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at com.github.retrooper.packetevents.util.adventure.GsonComponentSerializerExtended.deserializeOr(GsonComponentSerializerExtended.java:95) ~[?:?]
        at com.github.retrooper.packetevents.util.adventure.GsonComponentSerializerExtended.deserializeOr(GsonComponentSerializerExtended.java:43) ~[?:?]
        at net.kyori.adventure.text.serializer.ComponentSerializer.deserializeOrNull(ComponentSerializer.java:78) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at com.github.retrooper.packetevents.util.adventure.AdventureSerializer.parseComponent(AdventureSerializer.java:67) ~[?:?]
        at com.github.retrooper.packetevents.wrapper.PacketWrapper.readComponentAsJSON(PacketWrapper.java:537) ~[?:?]
        at com.github.retrooper.packetevents.wrapper.PacketWrapper.readComponent(PacketWrapper.java:524) ~[?:?]
        at com.github.retrooper.packetevents.wrapper.play.server.WrapperPlayServerSystemChatMessage.read(WrapperPlayServerSystemChatMessage.java:90) ~[?:?]
        at com.github.retrooper.packetevents.wrapper.PacketWrapper.readEvent(PacketWrapper.java:238) ~[?:?]
        at com.github.retrooper.packetevents.wrapper.PacketWrapper.<init>(PacketWrapper.java:143) ~[?:?]
        at com.github.retrooper.packetevents.wrapper.PacketWrapper.<init>(PacketWrapper.java:133) ~[?:?]
        at com.github.retrooper.packetevents.wrapper.play.server.WrapperPlayServerSystemChatMessage.<init>(WrapperPlayServerSystemChatMessage.java:50) ~[?:?]
        at net.pvpclash.clashvelocity.core.ChatRestoreManager$InternalPacketListener.extractMessage(ChatRestoreManager.java:91) ~[?:?]
        at net.pvpclash.clashvelocity.core.ChatRestoreManager$InternalPacketListener.onPacketSend(ChatRestoreManager.java:75) ~[?:?]
        at com.github.retrooper.packetevents.event.PacketListener$1.onPacketSend(PacketListener.java:46) ~[?:?]
        at com.github.retrooper.packetevents.event.PacketSendEvent.call(PacketSendEvent.java:51) ~[?:?]
        at com.github.retrooper.packetevents.event.EventManager.callEvent(EventManager.java:52) ~[?:?]
        at io.github.retrooper.packetevents.handlers.PacketEventsEncoder.read(PacketEventsEncoder.java:46) ~[?:?]
        at io.github.retrooper.packetevents.handlers.PacketEventsEncoder.encode(PacketEventsEncoder.java:65) ~[?:?]
        at io.github.retrooper.packetevents.handlers.PacketEventsEncoder.encode(PacketEventsEncoder.java:32) ~[?:?]
        at io.netty.handler.codec.MessageToByteEncoder.write(MessageToByteEncoder.java:107) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.invokeWrite0(AbstractChannelHandlerContext.java:881) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.invokeWrite(AbstractChannelHandlerContext.java:863) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.write(AbstractChannelHandlerContext.java:968) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.write(AbstractChannelHandlerContext.java:856) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.handler.codec.MessageToByteEncoder.write(MessageToByteEncoder.java:120) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.invokeWrite0(AbstractChannelHandlerContext.java:881) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.invokeWrite(AbstractChannelHandlerContext.java:863) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.write(AbstractChannelHandlerContext.java:968) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.write(AbstractChannelHandlerContext.java:856) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.DefaultChannelPipeline.write(DefaultChannelPipeline.java:1015) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannel.write(AbstractChannel.java:301) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at com.velocitypowered.proxy.connection.MinecraftConnection.delayedWrite(MinecraftConnection.java:243) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at com.velocitypowered.proxy.connection.backend.BackendPlaySessionHandler.handleUnknown(BackendPlaySessionHandler.java:338) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at com.velocitypowered.proxy.connection.MinecraftConnection.channelRead(MinecraftConnection.java:159) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:444) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:420) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:412) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at com.velocitypowered.proxy.protocol.netty.AutoReadHolderHandler.channelRead(AutoReadHolderHandler.java:57) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:442) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:420) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:412) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at com.velocitypowered.proxy.protocol.netty.MinecraftDecoder.tryDecode(MinecraftDecoder.java:78) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at com.velocitypowered.proxy.protocol.netty.MinecraftDecoder.channelRead(MinecraftDecoder.java:61) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:444) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:420) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:412) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.handler.codec.MessageToMessageDecoder.channelRead(MessageToMessageDecoder.java:103) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:444) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:420) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:412) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.handler.timeout.IdleStateHandler.channelRead(IdleStateHandler.java:286) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:442) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:420) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:412) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.handler.codec.ByteToMessageDecoder.fireChannelRead(ByteToMessageDecoder.java:346) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:318) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:444) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:420) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:412) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.DefaultChannelPipeline$HeadContext.channelRead(DefaultChannelPipeline.java:1410) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:440) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:420) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.DefaultChannelPipeline.fireChannelRead(DefaultChannelPipeline.java:919) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.epoll.AbstractEpollStreamChannel$EpollStreamUnsafe.epollInReady(AbstractEpollStreamChannel.java:800) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.epoll.EpollEventLoop.processReady(EpollEventLoop.java:509) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.epoll.EpollEventLoop.run(EpollEventLoop.java:407) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.util.concurrent.SingleThreadEventExecutor$4.run(SingleThreadEventExecutor.java:997) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at java.lang.Thread.run(Thread.java:840) [?:?]

Software brand
Velocity 3.3.0

How To Reproduce

  1. Join with the 1.20.2 minecraft client.
  2. Get some message (but sometimes it works, so not every message does this)

Important:
I am using this inside the listener (after type checks):

WrapperPlayServerSystemChatMessage.HANDLE_JSON = false;
new WrapperPlayServerSystemChatMessage(event).getMessageJson()

but even this doesn't fix the issue.

@BlackBaroness BlackBaroness added the bug Something isn't working label Jan 24, 2024
@BlackBaroness
Copy link
Author

Also there are another related issue when 1.20.3\1.20.4 player sees messages:

[09:54:41 WARN] [com.github.retrooper.packetevents.PacketEventsAPI]: PacketEvents caught an unhandled exception while calling your listener.
java.lang.IllegalStateException: Illegal component nbt key read: 'type'
        at com.github.retrooper.packetevents.util.adventure.AdventureNBTSerialization.readStyle(AdventureNBTSerialization.java:394) ~[?:?]
        at com.github.retrooper.packetevents.util.adventure.AdventureNBTSerialization.readComponent(AdventureNBTSerialization.java:739) ~[?:?]
        at com.github.retrooper.packetevents.util.adventure.AdventureNBTSerialization.readComponentList(AdventureNBTSerialization.java:952) ~[?:?]
        at com.github.retrooper.packetevents.util.adventure.AdventureNBTSerialization.readComponent(AdventureNBTSerialization.java:728) ~[?:?]
        at com.github.retrooper.packetevents.util.adventure.AdventureNBTSerialization.readComponent(AdventureNBTSerialization.java:604) ~[?:?]
        at com.github.retrooper.packetevents.util.adventure.AdventureNBTSerialization.readComponent(AdventureNBTSerialization.java:600) ~[?:?]
        at com.github.retrooper.packetevents.util.adventure.AdventureNBTSerialization.readComponent(AdventureNBTSerialization.java:595) ~[?:?]
        at com.github.retrooper.packetevents.wrapper.PacketWrapper.readComponentAsNBT(PacketWrapper.java:529) ~[?:?]
        at com.github.retrooper.packetevents.wrapper.PacketWrapper.readComponent(PacketWrapper.java:524) ~[?:?]
        at com.github.retrooper.packetevents.wrapper.play.server.WrapperPlayServerSystemChatMessage.read(WrapperPlayServerSystemChatMessage.java:90) ~[?:?]
        at com.github.retrooper.packetevents.wrapper.PacketWrapper.readEvent(PacketWrapper.java:238) ~[?:?]
        at com.github.retrooper.packetevents.wrapper.PacketWrapper.<init>(PacketWrapper.java:143) ~[?:?]
        at com.github.retrooper.packetevents.wrapper.PacketWrapper.<init>(PacketWrapper.java:133) ~[?:?]
        at com.github.retrooper.packetevents.wrapper.play.server.WrapperPlayServerSystemChatMessage.<init>(WrapperPlayServerSystemChatMessage.java:50) ~[?:?]
        at net.pvpclash.clashvelocity.core.ChatRestoreManager$InternalPacketListener.extractMessage(ChatRestoreManager.java:91) ~[?:?]
        at net.pvpclash.clashvelocity.core.ChatRestoreManager$InternalPacketListener.onPacketSend(ChatRestoreManager.java:75) ~[?:?]
        at com.github.retrooper.packetevents.event.PacketListener$1.onPacketSend(PacketListener.java:46) ~[?:?]
        at com.github.retrooper.packetevents.event.PacketSendEvent.call(PacketSendEvent.java:51) ~[?:?]
        at com.github.retrooper.packetevents.event.EventManager.callEvent(EventManager.java:52) ~[?:?]
        at io.github.retrooper.packetevents.handlers.PacketEventsEncoder.read(PacketEventsEncoder.java:46) ~[?:?]
        at io.github.retrooper.packetevents.handlers.PacketEventsEncoder.encode(PacketEventsEncoder.java:65) ~[?:?]
        at io.github.retrooper.packetevents.handlers.PacketEventsEncoder.encode(PacketEventsEncoder.java:32) ~[?:?]
        at io.netty.handler.codec.MessageToByteEncoder.write(MessageToByteEncoder.java:107) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.invokeWrite0(AbstractChannelHandlerContext.java:881) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.invokeWrite(AbstractChannelHandlerContext.java:863) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.write(AbstractChannelHandlerContext.java:968) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.write(AbstractChannelHandlerContext.java:856) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.handler.codec.MessageToByteEncoder.write(MessageToByteEncoder.java:120) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.invokeWrite0(AbstractChannelHandlerContext.java:881) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.invokeWrite(AbstractChannelHandlerContext.java:863) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.write(AbstractChannelHandlerContext.java:968) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.write(AbstractChannelHandlerContext.java:856) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.DefaultChannelPipeline.write(DefaultChannelPipeline.java:1015) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannel.write(AbstractChannel.java:301) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at com.velocitypowered.proxy.connection.MinecraftConnection.delayedWrite(MinecraftConnection.java:243) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at com.velocitypowered.proxy.connection.backend.BackendPlaySessionHandler.handleUnknown(BackendPlaySessionHandler.java:338) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at com.velocitypowered.proxy.connection.MinecraftConnection.channelRead(MinecraftConnection.java:159) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:444) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:420) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:412) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at com.velocitypowered.proxy.protocol.netty.AutoReadHolderHandler.channelRead(AutoReadHolderHandler.java:57) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:442) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:420) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:412) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at com.velocitypowered.proxy.protocol.netty.MinecraftDecoder.tryDecode(MinecraftDecoder.java:78) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at com.velocitypowered.proxy.protocol.netty.MinecraftDecoder.channelRead(MinecraftDecoder.java:61) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:444) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:420) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:412) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.handler.codec.MessageToMessageDecoder.channelRead(MessageToMessageDecoder.java:103) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:444) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:420) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:412) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.handler.timeout.IdleStateHandler.channelRead(IdleStateHandler.java:286) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:442) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:420) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:412) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.handler.codec.ByteToMessageDecoder.fireChannelRead(ByteToMessageDecoder.java:346) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.handler.codec.ByteToMessageDecoder.fireChannelRead(ByteToMessageDecoder.java:333) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.handler.codec.ByteToMessageDecoder.callDecode(ByteToMessageDecoder.java:454) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:290) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:444) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:420) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:412) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.DefaultChannelPipeline$HeadContext.channelRead(DefaultChannelPipeline.java:1410) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:440) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:420) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.DefaultChannelPipeline.fireChannelRead(DefaultChannelPipeline.java:919) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.epoll.AbstractEpollStreamChannel$EpollStreamUnsafe.epollInReady(AbstractEpollStreamChannel.java:800) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.epoll.EpollEventLoop.processReady(EpollEventLoop.java:509) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.channel.epoll.EpollEventLoop.run(EpollEventLoop.java:407) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.util.concurrent.SingleThreadEventExecutor$4.run(SingleThreadEventExecutor.java:997) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30) ~[velocity-3.3.0-SNAPSHOT-316.jar:3.3.0-SNAPSHOT (git-408b420a-b316)]
        at java.lang.Thread.run(Thread.java:840) [?:?]

@booky10
Copy link
Collaborator

booky10 commented Jan 24, 2024

The first issue should be resolved with #665, try using the latest snapshot version of packetevents

@BlackBaroness
Copy link
Author

The first issue should be resolved with #665, try using the latest snapshot version of packetevents

I use latest shapshot version already

@wordandahalf
Copy link
Contributor

I also can confirm this issue occurs on Velocity with 1.20.1 backends and 1.20.1 clients.

@booky10
Copy link
Collaborator

booky10 commented Jan 25, 2024

The first issue should be resolved with #665, try using the latest snapshot version of packetevents

I use latest shapshot version already

Are you about this? This exact same issue was fixed with 671c935

@BlackBaroness
Copy link
Author

The first issue should be resolved with #665, try using the latest snapshot version of packetevents

I use latest shapshot version already

Are you about this? This exact same issue was fixed with 671c935

Yes, when I saw this issue, I downloaded the latest snapshot. However, I will try again soon

@wordandahalf
Copy link
Contributor

The first issue should be resolved with #665, try using the latest snapshot version of packetevents

I use latest shapshot version already

Are you about this? This exact same issue was fixed with 671c935

In my instance, we didn't have any issues until that commit. Reverting to the commit before (c08719a) resolves the issue.

@SamB440
Copy link
Contributor

SamB440 commented Jan 25, 2024

The gson update did seem to fix my issue (#664), so there seems to be more things going on here, reverting that commit isn't the simple solution

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants