Skip to content
This repository has been archived by the owner on Apr 26, 2024. It is now read-only.

Fix exception when failing to get remote room list #10414

Merged
merged 3 commits into from
Jul 20, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions changelog.d/10414.bugfix
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Fix a number of logged errors caused by remote servers being down.
6 changes: 5 additions & 1 deletion synapse/handlers/room_list.py
Original file line number Diff line number Diff line change
Expand Up @@ -383,7 +383,11 @@ async def get_remote_public_room_list(
):
logger.debug("Falling back to locally-filtered /publicRooms")
else:
raise # Not an error that should trigger a fallback.
# Not an error that should trigger a fallback.
raise SynapseError(502, "Failed to fetch room list")
except RequestSendFailed:
# Not an error that should trigger a fallback.
raise SynapseError(502, "Failed to fetch room list")

# if we reach this point, then we fall back to the situation where
# we currently don't support searching across federation, so we have
Expand Down