-
-
Notifications
You must be signed in to change notification settings - Fork 639
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
Fix config phase packets getting lost #1316
Fix config phase packets getting lost #1316
Conversation
Does this theoretically resolve #1251? |
Shouldn't impact this issue. At first this PR only impacts client -> server packets, and only normally unrelevant packets. (at least when you don't use modded Minecraft) |
if (serverConn != null) { | ||
serverConn.ensureConnected().write(packet); | ||
} else { | ||
player.getConnection().write(packet); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
isn't this sending data to the wrong thing? you either want to get the connection in flight, or the connected server?
Closed in favour of #1326 as this is sending packets in the wrong direction |
connection is the clientbound connection, and this is the proxy handler acting as client? But the other PR is probably a better solution, I'll try. But this definitely works, as we use a client mod and the handshake worked correctly afterwards. |
ClientConfigSessionHandler is receiving packets from the client, hence why it has logic to write to the connection in-flight, so I'm honestly not sure how this would fix anything scratches head |
When the config-phase is initiated externally, packets are getting lost, as there is no
connectionInFlight
.This is most noticeable with
PluginMessagePacket
as some client-only mods initiate their state in the config phase. The servers request is receipt, but the client has no way to acknowledge the pm.One common scenario where it would occur is when you chain multiple Velocity servers. But it should be the expected behavior nonetheless.