Catch LimitOverrunError exception in main client loop

This commit is contained in:
Ben 2020-06-11 20:15:22 +01:00
parent edafefd8e7
commit d9fd35249b

View File

@ -1,4 +1,4 @@
from asyncio import CancelledError, IncompleteReadError
from asyncio import CancelledError, IncompleteReadError, LimitOverrunError
from xml.etree.cElementTree import Element, SubElement, tostring
import defusedxml.cElementTree as Et
@ -178,6 +178,8 @@ class Spheniscidae:
self.__writer.close()
except ConnectionResetError:
self.__writer.close()
except LimitOverrunError:
self.__writer.close()
except BaseException as e:
self.logger.exception(e.__traceback__)