Paper icon indicating copy to clipboard operation
Paper copied to clipboard

Error sending packet clientbound/minecraft:disconnect

Open Tencryn opened this issue 1 year ago • 8 comments

Stack trace

[20:51:10 ERROR]: Error sending packet clientbound/minecraft:disconnect (skippable? false)
io.netty.handler.codec.EncoderException: Sending unknown packet 'clientbound/minecraft:disconnect'
        at net.minecraft.network.codec.IdDispatchCodec.encode(IdDispatchCodec.java:46) ~[paper-1.20.6.jar:git-Paper-38]
        at net.minecraft.network.codec.IdDispatchCodec.encode(IdDispatchCodec.java:20) ~[paper-1.20.6.jar:git-Paper-38]
        at net.minecraft.network.PacketEncoder.encode(PacketEncoder.java:26) ~[paper-1.20.6.jar:git-Paper-38]
        at net.minecraft.network.PacketEncoder.encode(PacketEncoder.java:12) ~[paper-1.20.6.jar:git-Paper-38]
        at io.netty.handler.codec.MessageToByteEncoder.write(MessageToByteEncoder.java:107) ~[netty-codec-4.1.97.Final.jar:4.1.97.Final]
        at io.netty.channel.AbstractChannelHandlerContext.invokeWrite0(AbstractChannelHandlerContext.java:881) ~[netty-transport-4.1.97.Final.jar:4.1.97.Final]
        at io.netty.channel.AbstractChannelHandlerContext.invokeWrite(AbstractChannelHandlerContext.java:863) ~[netty-transport-4.1.97.Final.jar:4.1.97.Final]
        at io.netty.channel.AbstractChannelHandlerContext.write(AbstractChannelHandlerContext.java:968) ~[netty-transport-4.1.97.Final.jar:4.1.97.Final]
        at io.netty.channel.AbstractChannelHandlerContext.write(AbstractChannelHandlerContext.java:856) ~[netty-transport-4.1.97.Final.jar:4.1.97.Final]
        at io.netty.channel.ChannelOutboundHandlerAdapter.write(ChannelOutboundHandlerAdapter.java:113) ~[netty-transport-4.1.97.Final.jar:4.1.97.Final]
        at net.minecraft.network.Connection$2.write(Connection.java:748) ~[paper-1.20.6.jar:git-Paper-38]
        at io.netty.channel.AbstractChannelHandlerContext.invokeWrite0(AbstractChannelHandlerContext.java:881) ~[netty-transport-4.1.97.Final.jar:4.1.97.Final]
        at io.netty.channel.AbstractChannelHandlerContext.invokeWriteAndFlush(AbstractChannelHandlerContext.java:940) ~[netty-transport-4.1.97.Final.jar:4.1.97.Final]
        at io.netty.channel.AbstractChannelHandlerContext.write(AbstractChannelHandlerContext.java:966) ~[netty-transport-4.1.97.Final.jar:4.1.97.Final]
        at io.netty.channel.AbstractChannelHandlerContext.writeAndFlush(AbstractChannelHandlerContext.java:934) ~[netty-transport-4.1.97.Final.jar:4.1.97.Final]
        at io.netty.channel.AbstractChannelHandlerContext.writeAndFlush(AbstractChannelHandlerContext.java:984) ~[netty-transport-4.1.97.Final.jar:4.1.97.Final]
        at io.netty.channel.DefaultChannelPipeline.writeAndFlush(DefaultChannelPipeline.java:1025) ~[netty-transport-4.1.97.Final.jar:4.1.97.Final]
        at io.netty.channel.AbstractChannel.writeAndFlush(AbstractChannel.java:306) ~[netty-transport-4.1.97.Final.jar:4.1.97.Final]
        at net.minecraft.network.Connection.doSendPacket(Connection.java:503) ~[paper-1.20.6.jar:git-Paper-38]
        at net.minecraft.network.Connection.sendPacket(Connection.java:485) ~[paper-1.20.6.jar:git-Paper-38]
        at net.minecraft.network.Connection.send(Connection.java:447) ~[paper-1.20.6.jar:git-Paper-38]
        at net.minecraft.network.Connection.send(Connection.java:433) ~[paper-1.20.6.jar:git-Paper-38]
        at net.minecraft.network.Connection.exceptionCaught(Connection.java:219) ~[paper-1.20.6.jar:git-Paper-38]
        at io.netty.channel.AbstractChannelHandlerContext.invokeExceptionCaught(AbstractChannelHandlerContext.java:346) ~[netty-transport-4.1.97.Final.jar:4.1.97.Final]
        at io.netty.channel.AbstractChannelHandlerContext.invokeExceptionCaught(AbstractChannelHandlerContext.java:325) ~[netty-transport-4.1.97.Final.jar:4.1.97.Final]
        at io.netty.channel.AbstractChannelHandlerContext.fireExceptionCaught(AbstractChannelHandlerContext.java:317) ~[netty-transport-4.1.97.Final.jar:4.1.97.Final]
        at io.netty.handler.flush.FlushConsolidationHandler.exceptionCaught(FlushConsolidationHandler.java:159) ~[netty-handler-4.1.97.Final.jar:4.1.97.Final]
        at io.netty.channel.AbstractChannelHandlerContext.invokeExceptionCaught(AbstractChannelHandlerContext.java:346) ~[netty-transport-4.1.97.Final.jar:4.1.97.Final]
        at io.netty.channel.AbstractChannelHandlerContext.invokeExceptionCaught(AbstractChannelHandlerContext.java:325) ~[netty-transport-4.1.97.Final.jar:4.1.97.Final]
        at io.netty.channel.AbstractChannelHandlerContext.fireExceptionCaught(AbstractChannelHandlerContext.java:317) ~[netty-transport-4.1.97.Final.jar:4.1.97.Final]
        at io.netty.channel.DefaultChannelPipeline$HeadContext.exceptionCaught(DefaultChannelPipeline.java:1377) ~[netty-transport-4.1.97.Final.jar:4.1.97.Final]
        at io.netty.channel.AbstractChannelHandlerContext.invokeExceptionCaught(AbstractChannelHandlerContext.java:346) ~[netty-transport-4.1.97.Final.jar:4.1.97.Final]
        at io.netty.channel.AbstractChannelHandlerContext.invokeExceptionCaught(AbstractChannelHandlerContext.java:325) ~[netty-transport-4.1.97.Final.jar:4.1.97.Final]
        at io.netty.channel.DefaultChannelPipeline.fireExceptionCaught(DefaultChannelPipeline.java:907) ~[netty-transport-4.1.97.Final.jar:4.1.97.Final]
        at io.netty.channel.nio.AbstractNioByteChannel$NioByteUnsafe.handleReadException(AbstractNioByteChannel.java:125) ~[netty-transport-4.1.97.Final.jar:4.1.97.Final]
        at io.netty.channel.nio.AbstractNioByteChannel$NioByteUnsafe.read(AbstractNioByteChannel.java:177) ~[netty-transport-4.1.97.Final.jar:4.1.97.Final]
        at io.netty.channel.nio.NioEventLoop.processSelectedKey(NioEventLoop.java:788) ~[netty-transport-4.1.97.Final.jar:4.1.97.Final]
        at io.netty.channel.nio.NioEventLoop.processSelectedKeysOptimized(NioEventLoop.java:724) ~[netty-transport-4.1.97.Final.jar:4.1.97.Final]
        at io.netty.channel.nio.NioEventLoop.processSelectedKeys(NioEventLoop.java:650) ~[netty-transport-4.1.97.Final.jar:4.1.97.Final]
        at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:562) ~[netty-transport-4.1.97.Final.jar:4.1.97.Final]
        at io.netty.util.concurrent.SingleThreadEventExecutor$4.run(SingleThreadEventExecutor.java:997) ~[netty-common-4.1.97.Final.jar:4.1.97.Final]
        at io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74) ~[netty-common-4.1.97.Final.jar:4.1.97.Final]
        at java.base/java.lang.Thread.run(Thread.java:1583) ~[?:?]

Plugin and Datapack List

Bukkit Plugins:

  • CMI, CMILib, LuckPerms, Vault, WorldEdit

There are 3 data pack(s) enabled: [vanilla (built-in)], [file/bukkit (world)], [paper (built-in)]

Actions to reproduce (if known)

No response

Paper version

git-Paper-38 (MC: 1.20.6) (Implementing API version 1.20.6-R0.1-SNAPSHOT) (Git: 5632210)

Other

Not sure on what may have caused it. This one specifically occurred minutes after server startup, but I've had one that happened around 28 minutes after. My assumption is a bot joined and disconnected, but never encountered an error like this before. Due to the nature of the error, it's difficult to replicate so was unable to see if the error still occurs on Build 39 but as that build doesn't appear to contain packet changes, I would assume this error would still occur.

Tencryn avatar May 05 '24 02:05 Tencryn

With my plugins: Citizens, CMI, CMILib, DeluxeMenus, FastAsyncWorldEdit, PL-Hide, PlaceholderAPI, WorldGuard

Shows the same thing

alexfry756 avatar May 05 '24 06:05 alexfry756

Stumbled on that as well. I experienced it without plugins, using runDev via IDE. Server was in startup and my client pinged the server fairly early using the mulitplayer serverlist actively spamming the refresh.

yannicklamprecht avatar May 05 '24 08:05 yannicklamprecht

Pretty sure that this is purely due to a race condition in the vanilla server init logic, the connection exists before the packets are actually registered or something; it's been fairly possible to trigger variations of this for a short while in the server software

electronicboy avatar May 05 '24 09:05 electronicboy

Let's hope that it will be fixed soon :)

alexfry756 avatar May 05 '24 09:05 alexfry756

Let's hope that it will be fixed soon :)

It's nothing that harms the server. So no real issues, just a cosmetic problem in the log.

Probably can be avoided by activating "late port bind".

yannicklamprecht avatar May 05 '24 09:05 yannicklamprecht

Stumbled on that as well. I experienced it without plugins, using runDev via IDE. Server was in startup and my client pinged the server fairly early using the mulitplayer serverlist actively spamming the refresh.

I can replicate that, so it may be the same issue however it's not exclusive to server start up as I've had it occur long after. I cannot replicate it after startup, but I am locally hosting so that's probably why.

Tencryn avatar May 05 '24 15:05 Tencryn

please, add to this issuse status lables - type: bug, and version: 1.20.6

alexfry756 avatar May 05 '24 16:05 alexfry756

the author of the paper core.. Please read this and fix it, this error is clogging up the console very much(

alexfry756 avatar May 08 '24 18:05 alexfry756

well, another report of this somewhat suggest that maybe it's not a race and something is trying to send a disconnection in the wrong protocol phase

Are these plugin induced kicks? anybody have a means to reproduce this sanely?

electronicboy avatar May 29 '24 06:05 electronicboy

Yes, this can happen without any plugins or config changes. Although just for anyone reading this, the error is entirely harmless

kennytv avatar May 29 '24 09:05 kennytv

It is a bit annoying though, is there a workaround to get rid of it? Or do we just wait for a patch?

luftwafflezz avatar May 29 '24 12:05 luftwafflezz

It is a bit annoying though, is there a workaround to get rid of it? Or do we just wait for a patch?

You could use a plugin like LogFilter to just hide the message for the time being.

codebycam avatar May 29 '24 12:05 codebycam

but will this mistake really remain and we will have to hide it through workarounds? This mistake never happened, and now it will forever remind you of itself as a flawed flaw.

alexfry756 avatar May 29 '24 12:05 alexfry756

but will this mistake really remain and we will have to hide it through workarounds? This mistake never happened, and now it will forever remind you of itself as a flawed flaw.

If I understood your brain aneurysm correctly, no, Paper will patch it eventually.

luftwafflezz avatar May 29 '24 13:05 luftwafflezz

but will this mistake really remain and we will have to hide it through workarounds? This mistake never happened, and now it will forever remind you of itself as a flawed flaw.

It will eventually be fixed, but it is a low priority as it is harmless (PRs welcome)!

@Luftwaffle46 please don't make nasty comments to other users.

codebycam avatar May 29 '24 13:05 codebycam

I too am experiencing this throughout my initial 1.20.6 test runs. (Build 115) Appreciate it being marked as accepted, thank you! :)

andrewkm avatar May 29 '24 17:05 andrewkm

https://bugs.mojang.com/browse/MC-271325

electronicboy avatar May 29 '24 17:05 electronicboy

https://github.com/PaperMC/Paper/commit/8e6554a80a1efefa48adb1f7733554e528fb45f5

electronicboy avatar May 30 '24 18:05 electronicboy

Confirmed fixed. :)

andrewkm avatar May 30 '24 18:05 andrewkm