fix? why doesn't ig exist

This commit is contained in:
əlemi 2022-05-23 02:58:20 +02:00
parent 7ffc69d8c2
commit 9c5d0aa57d
No known key found for this signature in database
GPG key ID: BBCBFE5D7244634E

View file

@ -61,7 +61,7 @@ class MinecraftClient:
# TODO can we just use the 1st record?
host = str(answ[0].target).rstrip('.')
port = answ[0].port
except dns.resolver.exception.DNSException: # TODO is this the right thing to catch?
except Exception: # TODO what can I catch? dns.resolver.exception doesn't always exist, wtf
self.logger.warning("Failed resolving SRV record for '%s'", server)
self.dispatcher = Dispatcher().set_host(host, port)