String too Big
AllieSniperian opened this issue ยท 2 comments
When there is a large number of structures in a mod pack, the compass's GUI will fail to open, in the logs
Some possible solutions as suggested by a modder I'm in communication with;
A: Increase the packet size.
B: Condense the packet.
C: Send multiple packets.
io.netty.handler.codec.EncoderException: String too big (was 33800 bytes encoded, max 32767)
at net.minecraft.network.PacketBuffer.func_211400_a(PacketBuffer.java:363) ~[?:?]
at net.minecraft.network.PacketBuffer.func_180714_a(PacketBuffer.java:357) ~[?:?]
at com.github.samarium150.structurescompass.network.packet.SyncPacket.toBytes(SyncPacket.java:77) ~[?:1.16.5-1.1.0]
at com.github.samarium150.structurescompass.network.StructuresCompassNetwork$$Lambda$17199/2135300254.accept(Unknown Source) ~[?:?]
at net.minecraftforge.fml.network.simple.IndexedMessageCodec.lambda$tryEncode$4(IndexedMessageCodec.java:134) ~[?:?]
at net.minecraftforge.fml.network.simple.IndexedMessageCodec$$Lambda$22324/1749512004.accept(Unknown Source) ~[?:?]
at java.util.Optional.ifPresent(Optional.java:159) ~[?:1.8.0_51]
at net.minecraftforge.fml.network.simple.IndexedMessageCodec.tryEncode(IndexedMessageCodec.java:132) ~[?:?]
at net.minecraftforge.fml.network.simple.IndexedMessageCodec.build(IndexedMessageCodec.java:147) ~[?:?]
at net.minecraftforge.fml.network.simple.SimpleChannel.encodeMessage(SimpleChannel.java:85) ~[?:?]
at net.minecraftforge.fml.network.simple.SimpleChannel.toBuffer(SimpleChannel.java:98) ~[?:?]
at net.minecraftforge.fml.network.simple.SimpleChannel.toVanillaPacket(SimpleChannel.java:129) ~[?:?]
at net.minecraftforge.fml.network.simple.SimpleChannel.send(SimpleChannel.java:124) ~[?:?]
at com.github.samarium150.structurescompass.network.packet.RequestSyncPacket.lambda$handle$2(RequestSyncPacket.java:49) ~[?:1.16.5-1.1.0]
at com.github.samarium150.structurescompass.network.packet.RequestSyncPacket$$Lambda$24638/1417132502.run(Unknown Source) ~[?:?]
at net.minecraftforge.fml.network.NetworkEvent$Context.enqueueWork(NetworkEvent.java:215) ~[?:?]
at com.github.samarium150.structurescompass.network.packet.RequestSyncPacket.handle(RequestSyncPacket.java:39) ~[?:1.16.5-1.1.0]
at com.github.samarium150.structurescompass.network.StructuresCompassNetwork$$Lambda$17198/841226209.accept(Unknown Source) ~[?:?]
at net.minecraftforge.fml.network.simple.IndexedMessageCodec.lambda$tryDecode$3(IndexedMessageCodec.java:128) ~[?:?]
at net.minecraftforge.fml.network.simple.IndexedMessageCodec$$Lambda$22596/1404344875.accept(Unknown Source) ~[?:?]
at java.util.Optional.ifPresent(Optional.java:159) ~[?:1.8.0_51]
at net.minecraftforge.fml.network.simple.IndexedMessageCodec.tryDecode(IndexedMessageCodec.java:128) ~[?:?]
at net.minecraftforge.fml.network.simple.IndexedMessageCodec.consume(IndexedMessageCodec.java:162) ~[?:?]
at net.minecraftforge.fml.network.simple.SimpleChannel.networkEventListener(SimpleChannel.java:80) ~[?:?]
at net.minecraftforge.fml.network.simple.SimpleChannel$$Lambda$2940/1710901767.accept(Unknown Source) ~[?:?]
at net.minecraftforge.eventbus.EventBus.doCastFilter(EventBus.java:247) ~[eventbus-4.0.0.jar:?]
at net.minecraftforge.eventbus.EventBus.lambda$addListener$11(EventBus.java:239) ~[eventbus-4.0.0.jar:?]
at net.minecraftforge.eventbus.EventBus$$Lambda$2942/976592764.invoke(Unknown Source) ~[?:?]
at net.minecraftforge.eventbus.EventBus$$Lambda$2578/581225655.invoke(Unknown Source) ~[?:?]
at net.minecraftforge.eventbus.EventBus.post(EventBus.java:302) ~[eventbus-4.0.0.jar:?]
at net.minecraftforge.eventbus.EventBus.post(EventBus.java:283) ~[eventbus-4.0.0.jar:?]
at net.minecraftforge.fml.network.NetworkInstance.dispatch(NetworkInstance.java:86) ~[?:?]
at net.minecraftforge.fml.network.NetworkHooks.lambda$onCustomPayload$1(NetworkHooks.java:91) ~[?:?]
at net.minecraftforge.fml.network.NetworkHooks$$Lambda$22582/1738679494.apply(Unknown Source) ~[?:?]
at java.util.Optional.map(Optional.java:215) ~[?:1.8.0_51]
at net.minecraftforge.fml.network.NetworkHooks.onCustomPayload(NetworkHooks.java:91) ~[?:?]
at net.minecraft.network.play.ServerPlayNetHandler.func_147349_a(ServerPlayNetHandler.java:1413) ~[?:?]
at net.minecraft.network.play.client.CCustomPayloadPacket.func_148833_a(CCustomPayloadPacket.java:42) ~[?:?]
at net.minecraft.network.play.client.CCustomPayloadPacket.func_148833_a(CCustomPayloadPacket.java:12) ~[?:?]
at net.minecraft.network.PacketThreadUtil.func_225383_a(SourceFile:21) ~[?:?]
at net.minecraft.network.PacketThreadUtil$$Lambda$22858/102912752.run(Unknown Source) ~[?:?]
at net.minecraft.util.concurrent.TickDelayedTask.run(SourceFile:18) ~[?:?]
at net.minecraft.util.concurrent.ThreadTaskExecutor.func_213166_h(SourceFile:144) [?:?]
at net.minecraft.util.concurrent.RecursiveEventLoop.func_213166_h(SourceFile:23) [?:?]
at net.minecraft.server.MinecraftServer.func_213166_h(MinecraftServer.java:734) [?:?]
at net.minecraft.server.MinecraftServer.func_213166_h(MinecraftServer.java:159) [?:?]
at net.minecraft.util.concurrent.ThreadTaskExecutor.func_213168_p(SourceFile:118) [?:?]
at net.minecraft.server.MinecraftServer.func_213205_aW(MinecraftServer.java:717) [?:?]
at net.minecraft.server.MinecraftServer.func_213168_p(MinecraftServer.java:711) [?:?]
at net.minecraft.util.concurrent.ThreadTaskExecutor.func_213160_bf(SourceFile:103) [?:?]
at net.minecraft.server.MinecraftServer.func_213202_o(MinecraftServer.java:696) [?:?]
at net.minecraft.server.MinecraftServer.func_240802_v_(MinecraftServer.java:646) [?:?]
at net.minecraft.server.MinecraftServer.func_240783_a_(MinecraftServer.java:232) [?:?]
at net.minecraft.server.MinecraftServer$$Lambda$21630/901874112.run(Unknown Source) [?:?]
at java.lang.Thread.run(Thread.java:745) [?:1.8.0_51]
Thanks for your report. It's an known issue reported one in #7. We'll try to fix it soon.