
[Bug]: Internal Exception: io.netty.handler.codec.EncoderException:Failed to encode packet 'clientbound/minecraft:update_recipes'
ZephyrWindSpirit opened this issue ยท 6 comments
Minecraft Version
1.21.1
Forge Version
21.1.132
Mod Version
1.0.2
Details
[20/03/2025 19:26:11 PM] [19:26:11] [Server thread/INFO] [minecraft/ServerGamePacketListenerImpl]: MINECRAFTUSERNAME lost connection: Internal Exception: io.netty.handler.codec.EncoderException: Failed to encode packet 'clientbound/minecraft:update_recipes'
https://mclo.gs/kFkBFC6
I appear to have corrupted my instance? Believes I'm in multiplayer but I'm not. I've had this issue since trying to connect to a public server with my extra mods installed (yes it was a bad idea). After that it also refuses to enter single player. The issue disappears if I remove the mod.
Extra mods: supplementaries, mmmmmmmmmm, prefab, abyssal decor, sparse structures, handcrafted, dusty decorations, dawn of time builder edition, yetanotherconfiglib, william wythers overhauled overworld, better brightness slider, travelers titles, trade cycling
Disabled mods: almost unified, crash assistant, justzoom, konkrete
Per someone else who can read reports, this was dug out of the mess.
Caused by: io.netty.handler.codec.EncoderException: Empty ItemStack not allowed
[21/03/2025 02:28:45 AM] at TRANSFORMER/[email protected]/net.minecraft.world.item.ItemStack$2.encode(ItemStack.java:167) ~[client-1.21.1-20240808.144430-srg.jar%23455!/:?] {re:classloading}
[21/03/2025 02:28:45 AM] at TRANSFORMER/[email protected]/net.minecraft.world.item.ItemStack$2.encode(ItemStack.java:155) ~[client-1.21.1-20240808.144430-srg.jar%23455!/:?] {re:classloading}
[21/03/2025 02:28:45 AM] at TRANSFORMER/[email protected]/com.prefab.recipe.ConditionedShapedRecipe$Serializer.toNetwork(ConditionedShapedRecipe.java:251) ~[prefab-neoforge-1.0.2.jar%23649!/:?] {re:classloading}
Prefab's name may be in the list but that doesn't mean we are the cause. There are also a lot of other mods in your list so the same comment goes for them too. Looking at the log even I cannot tell which mod is causing the error.
Prefab works in isolation and mods interact in mysterious ways ๐ so your best bet would be to disable some mods and see if things work to work out which mod is the real culprit.
For the comment about the game thinking you are in multi-player but you are in a single-player world. That is one of the oddities of Minecraft in that every game is multi-player. This is why when you are playing in a single-player world you can open it up for a LAN connection and include people on your network to play with you. It's a neat little trick but it can be confusing for those that don't know about it.
This happened on my server too. The server worked perfectly for some time but at some point after a restart, everyone that tried to connect were instantly kicked with the same error. Removed Prefab and it begun working again.
This was on the ATM10 modpack.