mirror of
https://github.com/matrix-org/synapse.git
synced 2025-10-07 21:41:43 +02:00
Better warning in logs when we fail to fetch an alias (#15922)
**Before:** ``` Error retrieving alias ``` **After:** ``` Error retrieving alias #foo:bar -> 401 Unauthorized ``` *Spawning from creating the [manual testing strategy for the outbound federation proxy](https://github.com/matrix-org/synapse/pull/15773).*
This commit is contained in:
parent
d7fc87d973
commit
ae391db777
1
changelog.d/15922.misc
Normal file
1
changelog.d/15922.misc
Normal file
@ -0,0 +1 @@
|
|||||||
|
Add details to warning in log when we fail to fetch an alias.
|
@ -277,7 +277,9 @@ class DirectoryHandler:
|
|||||||
except RequestSendFailed:
|
except RequestSendFailed:
|
||||||
raise SynapseError(502, "Failed to fetch alias")
|
raise SynapseError(502, "Failed to fetch alias")
|
||||||
except CodeMessageException as e:
|
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:
|
if e.code == 404:
|
||||||
fed_result = None
|
fed_result = None
|
||||||
else:
|
else:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user