diff --git a/rcon/source/proto.py b/rcon/source/proto.py index 4c00af9..f14567e 100644 --- a/rcon/source/proto.py +++ b/rcon/source/proto.py @@ -2,6 +2,7 @@ from __future__ import annotations from asyncio import StreamReader +from contextlib import suppress from enum import Enum from functools import partial from logging import getLogger @@ -116,7 +117,8 @@ class Packet(NamedTuple): # Attempt to read following packets on large responses. if size >= max_pkg_size: - payload += cls.read(file, max_pkg_size=max_pkg_size).payload + with suppress(TimeoutError): + payload += cls.read(file, max_pkg_size=max_pkg_size).payload return cls(id_, type_, payload, terminator)