Remove unpack_dispatch_and_ack method

This commit is contained in:
Dan 2018-05-06 14:55:41 +02:00
parent 7f27c43b30
commit e270c7d5f8

View File

@ -259,13 +259,6 @@ class Session:
break break
try: try:
self.unpack_dispatch_and_ack(packet)
except Exception as e:
log.error(e, exc_info=True)
log.debug("{} stopped".format(name))
def unpack_dispatch_and_ack(self, packet: bytes):
data = self.unpack(BytesIO(packet)) data = self.unpack(BytesIO(packet))
messages = ( messages = (
@ -315,6 +308,10 @@ class Session:
pass pass
else: else:
self.pending_acks.clear() self.pending_acks.clear()
except Exception as e:
log.error(e, exc_info=True)
log.debug("{} stopped".format(name))
def ping(self): def ping(self):
log.debug("PingThread started") log.debug("PingThread started")