From 205bf888242ddefbeec61a47691e47693b4f12d2 Mon Sep 17 00:00:00 2001 From: Eric Eastwood Date: Tue, 11 Jul 2023 14:18:50 -0500 Subject: [PATCH 1/2] Better warning in logs when we fail to fetch an alias --- synapse/handlers/directory.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/synapse/handlers/directory.py b/synapse/handlers/directory.py index 1e0623c7f87f..623a4e7b1d5d 100644 --- a/synapse/handlers/directory.py +++ b/synapse/handlers/directory.py @@ -277,7 +277,9 @@ async def get_association(self, room_alias: RoomAlias) -> JsonDict: except RequestSendFailed: raise SynapseError(502, "Failed to fetch alias") except CodeMessageException as e: - logging.warning("Error retrieving alias") + logging.warning( + "Error retrieving alias %s -> %s %s", room_alias, e.code, e.msg + ) if e.code == 404: fed_result = None else: From 293fbf89f88bab701fe80fa7af6c49d61fab159f Mon Sep 17 00:00:00 2001 From: Eric Eastwood Date: Tue, 11 Jul 2023 14:27:22 -0500 Subject: [PATCH 2/2] Add changelog --- changelog.d/15922.misc | 1 + 1 file changed, 1 insertion(+) create mode 100644 changelog.d/15922.misc diff --git a/changelog.d/15922.misc b/changelog.d/15922.misc new file mode 100644 index 000000000000..93fc64487759 --- /dev/null +++ b/changelog.d/15922.misc @@ -0,0 +1 @@ +Add details to warning in log when we fail to fetch an alias.