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
Some bug will kick player out of server by collecting the drones #990
Comments
Hmm, seen problems like this before and I'd hoped I'd fixed them, but I guess not. Seems to be hard to do anything with I will continue to investigate, although this could be hard to debug since it never happens in a dev world. |
i would be more than happy to try out some debug builds of the mod on my enigmatica 6 expert server & try to intentionally trigger it if it would help you to gather the required information 🤔 |
Thanks, I'll let you know if I have a build to test. |
Build 317 from https://jenkins.k-4u.nl/job/PneumaticCraft-Repressurized-1.16/ is ready for testing, may or may not help... |
「desht ***@***.***>」在 2022年4月23日 週六,下午7:56 寫道:
Build 317 from
https://jenkins.k-4u.nl/job/PneumaticCraft-Repressurized-1.16/ is ready
for testing, may or may not help...
—
Reply to this email directly, view it on GitHub
<#990 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AOUCX4POVUJR7OSCJWJCKTLVGPQOLANCNFSM5TSG5NHA>
.
You are receiving this because you authored the thread.Message ID:
***@***.***>
Thanks for helping
|
@desht two server members still crashed when i picked up one of my drones, this is the error from the server console:
(the server, me, and both player names mentioned in the log were all running 517) |
Oh well, so much for that idea 😞 |
i recently had another accidental crash of a player, i took a harvester drone out of rs storage and held it in my inventory just fine, but the moment i selected the slot in the hotbar so i held it one of my players crashed again, so it might be less (or also) pickup related and more like "rendering in a player's hand" error, but that's just a guess. what i can tell from said recent occurrence is that only one of the players nearby crashed, two others didn't crash, i did not pay attention to distance or which way they were looking, if that matters at all.
any more ideas or ways to debug? |
Yeah, the problem is when the server sync's the (pressurizable) item a player is holding to other clients that are nearby. I know what's going wrong, but I'm still trying to figure out a way to prevent the problem occurring... |
OK, build 318 will be available shortly, with another attempt (and if this doesn't fix it, the stack trace might be more informative than before...) |
While trying to crash a player standing afk by holding drones, someone joined and while joining (not even completely loaded in/rendering yet) he crashed, all on 318:
|
the only difference i am noticing is |
Yeah, definitely trying to iterate the NBT keyset, as I thought... Question: does this only happen when there's more than one player online (or specifically in range of the player equipping the drone) ? Does it happen if there's only one other player present? |
Ill have to run some additional tests, during the last crash attempt i was within a few blocks of an afk player swapping through 3 different drones in my hotbar and he didn't crash (not 100% if i stood with his fov), but another player that joined and was in that dimension did immediately crash upon joining. Usually when several players are connected only one or two players tend to crash, but at those times i did not take into account server join order or dimension join order. I'll try to see if i can trigger single players to crash, memory regarding the previous attempts is blurry at best so a new round of testing is required. |
i am currently having trouble reproducing it, two players connected while i loaded in, i've tried holding/dropping/plonking/scrolling drones and nothing causes anyone to crash, even asking one of the players who joined later than me to reconnect incase it was somehow related to the join order. and just as i was typing this i returned to the main base (again) with a drone in hand, and now the member that didn't reconnect & whom i've visited several times with drones just now crashed:
|
My theory is that it happens when there's more than one other player around. And if I'm right, it's a Forge problem which I can't do much about, other than report it. Although I can just disable the NBT modification when sync'ing to client, which will get rid of the problem, but potentially increase the amount of network chatter from server to (each) client. But there may be no way around that in the short term. |
a bit more network traffic in exchange for not crashing seems like a good deal for now 🤔 |
- work around problems with pressure rounding in sync'd NBT data which can cause players to be kicked #990
Yep. Next build (319) will add a config setting |
- work around problems with pressure rounding in sync'd NBT data which can cause players to be kicked #990
@Quezler when you have a chance, would you be able to test build 321? (ensuring that I think I found a situation where I might end up modifying NBT on the network thread, and this build should fix that. |
sure, i'll give it a go 👍 |
Sorry for the late response, there haven't been many other players online during the moments i was working on pnc, but 321 hasn't (to my knowledge) caused anyone to crash yet, but due to the aforementioned reason it might be inconclusive. 🤔 |
Ok, thanks. Ideally need to test what happens when someone picks up a drone with at least 2 other players present. |
Describe the bug
I discover a bug where when a drone is destroy and collected by other players who did not place will cause the server become buggy and kick people out of the server.
How to reproduce the bug
I place a harvesting drone, and another player destroys it and collects it. Me and my friend are kicked out of the server with this description : Internal Exception: io.netty.handler.codec.EncoderException: java.util.ConcurrentModificationException
Expected behavior
Please fix it
Additional details
here is the server log
[18:45:43] [Server thread/INFO] [minecraft/DedicatedServer]: kenken311 left the game
[18:45:43] [Netty Server IO #18/ERROR] [minecraft/NettyPacketEncoder]: Error encoding packet
java.util.ConcurrentModificationException: null
at java.util.HashMap$HashIterator.nextNode(Unknown Source) ~[?:1.8.0_311] {}
at java.util.HashMap$KeyIterator.next(Unknown Source) ~[?:1.8.0_311] {}
at me.desht.pneumaticcraft.common.util.PneumaticCraftUtils.copyNBTWithout(PneumaticCraftUtils.java:713) ~[pneumaticcraft:1.16.5-2.15.6-315] {re:classloading}
at me.desht.pneumaticcraft.common.item.ItemPressurizable.roundedPressure(ItemPressurizable.java:156) ~[pneumaticcraft:1.16.5-2.15.6-315] {re:classloading}
at me.desht.pneumaticcraft.common.item.ItemPressurizable.getShareTag(ItemPressurizable.java:112) ~[pneumaticcraft:1.16.5-2.15.6-315] {re:classloading}
at net.minecraftforge.common.extensions.IForgeItemStack.getShareTag(IForgeItemStack.java:376) ~[forge:?] {re:mixin,re:computing_frames,re:classloading,pl:mixin:APP:apotheosis.mixins.json:MixinIForgeItemStack,pl:mixin:A}
at net.minecraft.network.PacketBuffer.writeItemStack(PacketBuffer.java:308) ~[?:?] {re:classloading}
at net.minecraft.network.PacketBuffer.func_150788_a(PacketBuffer.java:290) ~[?:?] {re:classloading}
at net.minecraft.network.play.server.SEntityEquipmentPacket.func_148840_b(SourceFile:54) ~[?:?] {re:classloading}
at net.minecraft.network.NettyPacketEncoder.encode(NettyPacketEncoder.java:38) ~[?:?] {re:classloading}
at net.minecraft.network.NettyPacketEncoder.encode(NettyPacketEncoder.java:12) ~[?:?] {re:classloading}
at io.netty.handler.codec.MessageToByteEncoder.write(MessageToByteEncoder.java:107) ~[server-1.16.5-20210115.111550-extra.jar:?] {}
at io.netty.channel.AbstractChannelHandlerContext.invokeWrite0(AbstractChannelHandlerContext.java:738) ~[server-1.16.5-20210115.111550-extra.jar:?] {}
at io.netty.channel.AbstractChannelHandlerContext.invokeWrite(AbstractChannelHandlerContext.java:730) ~[server-1.16.5-20210115.111550-extra.jar:?] {}
at io.netty.channel.AbstractChannelHandlerContext.write(AbstractChannelHandlerContext.java:816) ~[server-1.16.5-20210115.111550-extra.jar:?] {}
at io.netty.channel.AbstractChannelHandlerContext.write(AbstractChannelHandlerContext.java:723) ~[server-1.16.5-20210115.111550-extra.jar:?] {}
at io.netty.handler.codec.MessageToMessageEncoder.write(MessageToMessageEncoder.java:111) ~[server-1.16.5-20210115.111550-extra.jar:?] {}
at io.netty.channel.AbstractChannelHandlerContext.invokeWrite0(AbstractChannelHandlerContext.java:738) ~[server-1.16.5-20210115.111550-extra.jar:?] {}
at io.netty.channel.AbstractChannelHandlerContext.invokeWriteAndFlush(AbstractChannelHandlerContext.java:801) ~[server-1.16.5-20210115.111550-extra.jar:?] {}
at io.netty.channel.AbstractChannelHandlerContext.write(AbstractChannelHandlerContext.java:814) ~[server-1.16.5-20210115.111550-extra.jar:?] {}
at io.netty.channel.AbstractChannelHandlerContext.writeAndFlush(AbstractChannelHandlerContext.java:794) ~[server-1.16.5-20210115.111550-extra.jar:?] {}
at io.netty.channel.AbstractChannelHandlerContext.writeAndFlush(AbstractChannelHandlerContext.java:831) ~[server-1.16.5-20210115.111550-extra.jar:?] {}
at io.netty.channel.DefaultChannelPipeline.writeAndFlush(DefaultChannelPipeline.java:1071) ~[server-1.16.5-20210115.111550-extra.jar:?] {}
at io.netty.channel.AbstractChannel.writeAndFlush(AbstractChannel.java:300) ~[server-1.16.5-20210115.111550-extra.jar:?] {}
at net.minecraft.network.NetworkManager.lambda$sendPacket$5(NetworkManager.java:196) ~[?:?] {re:classloading,pl:runtimedistcleaner:A,re:mixin,pl:runtimedistcleaner:A}
at io.netty.util.concurrent.AbstractEventExecutor.safeExecute(AbstractEventExecutor.java:163) [server-1.16.5-20210115.111550-extra.jar:?] {}
at io.netty.util.concurrent.SingleThreadEventExecutor.runAllTasks(SingleThreadEventExecutor.java:404) [server-1.16.5-20210115.111550-extra.jar:?] {}
at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:465) [server-1.16.5-20210115.111550-extra.jar:?] {}
at io.netty.util.concurrent.SingleThreadEventExecutor$5.run(SingleThreadEventExecutor.java:884) [server-1.16.5-20210115.111550-extra.jar:?] {}
at java.lang.Thread.run(Unknown Source) [?:1.8.0_311] {}
Which Minecraft version are you using?
1.16
Crash log
No response
The text was updated successfully, but these errors were encountered: