From 992719554f05bc4526f99e5f208acf0ab068576b Mon Sep 17 00:00:00 2001 From: miruka Date: Mon, 16 Mar 2020 00:31:31 -0400 Subject: [PATCH] Log the involved user id in sync failures --- src/backend/matrix_client.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/backend/matrix_client.py b/src/backend/matrix_client.py index 2e001e2b..1433e786 100644 --- a/src/backend/matrix_client.py +++ b/src/backend/matrix_client.py @@ -274,7 +274,11 @@ class MatrixClient(nio.AsyncClient): trace = traceback.format_exc().rstrip() if isinstance(err, MatrixError) and err.http_code >= 500: - log.warning("Server failure during sync:\n%s", trace) + log.warning( + "Server failure during sync for %s:\n%s", + self.user_id, + trace, + ) else: LoopException(str(err), err, trace)