Ignore more network related errors during websocket communication.

Intermittent network issues during websocket communication should not crash ComfyUi process.
This commit is contained in:
Xiaodong Xie 2024-10-17 18:25:42 +02:00
parent 7390ff3b1e
commit 3b8d2385b7

View File

@ -40,7 +40,7 @@ class BinaryEventTypes:
async def send_socket_catch_exception(function, message):
try:
await function(message)
except (aiohttp.ClientError, aiohttp.ClientPayloadError, ConnectionResetError) as err:
except (aiohttp.ClientError, aiohttp.ClientPayloadError, ConnectionResetError, BrokenPipeError, ConnectionError) as err:
logging.warning("send error: {}".format(err))
def get_comfyui_version():