Ping Issue
ngi-odoo opened this issue · comments
Describe the bug
When pinging the server with version 1.15.2 or 1.16.4, an error is displayed on the server
To Reproduce
Steps to reproduce the behavior:
- Launch Minecraft 1.15.2
- Go to Multiplayer
- An error is displayed on the server
Expected behavior
No error
Error
This error occures when pinging with 1.16.4 (Error from @Geolykt)
PlayerNetwork{127.0.0.1} | ERROR | No name known for packet: (754, 'status', 'upstream', 0)
Traceback (most recent call last):
File "/home/Geolykt/.local/lib/python3.9/site-packages/quarry/net/protocol.py", line 207, in get_packet_name
return packets.packet_names[key]
KeyError: (754, 'status', 'upstream', 0)
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/Geolykt/.local/lib/python3.9/site-packages/quarry/net/protocol.py", line 243, in data_received
name = self.get_packet_name(buff.unpack_varint())
File "/home/Geolykt/.local/lib/python3.9/site-packages/quarry/net/protocol.py", line 209, in get_packet_name
raise ProtocolError("No name known for packet: %s" % (key,))
quarry.net.protocol.ProtocolError: No name known for packet: (754, 'status', 'upstream', 0)
Host system:
- OS: Windows
- OS version: 10
Additional context
Maybe a quarry issue ?
It looks like 1.16.4 is not supported, I've opened a ticket to quarry:
barneygale/quarry#102
The error quoted was occurring on Fedora 33 (GNU/Linux), but that's what I've been thinking too.
The issue is inherent in the structure of the project (quarry) but I believe with some overloading this should be fixable
Agreed
This is actually a bit harder than I thought it would be. While I fixed it by changing the implementation of two methods in quarry's protocol.py to
def get_packet_name(self, ident):
protver = self.protocol_version
if self.protocol_mode == 'status':
protver = 578
key = (protver, self.protocol_mode, self.recv_direction,
ident)
try:
return packets.packet_names[key]
except KeyError:
raise ProtocolError("No name known for packet: %s" % (key,))
def get_packet_ident(self, name):
protver = self.protocol_version
if self.protocol_mode == 'status':
protver = 578
key = (protver, self.protocol_mode, self.send_direction,
name)
try:
return packets.packet_idents[key]
except KeyError:
raise ProtocolError("No ID known for packet: %s" % (key,))
this is not a viable approach as it would mean that we will need to fork Quarry or push a PR to change that code, but I doubt they will accept such a PR. Does anyone have a better idea on how to go about it?