summary refs log tree commit diff
path: root/synapse/federation
diff options
context:
space:
mode:
authorSean Quah <8349537+squahtx@users.noreply.github.com>2022-05-31 15:50:29 +0100
committerGitHub <noreply@github.com>2022-05-31 15:50:29 +0100
commit2fba1076c56e76410fd901120f0e8df2ef33d1c4 (patch)
treee4212594882123e4396753296126693cdedfd7b9 /synapse/federation
parentMerge branch 'master' into develop (diff)
downloadsynapse-2fba1076c56e76410fd901120f0e8df2ef33d1c4.tar.xz
Faster room joins: Try other destinations when resyncing the state of a partial-state room (#12812)
Signed-off-by: Sean Quah <seanq@matrix.org>
Diffstat (limited to 'synapse/federation')
-rw-r--r--synapse/federation/federation_client.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/synapse/federation/federation_client.py b/synapse/federation/federation_client.py
index 17eff60909..b60b8983ea 100644
--- a/synapse/federation/federation_client.py
+++ b/synapse/federation/federation_client.py
@@ -405,6 +405,9 @@ class FederationClient(FederationBase):
 
         Returns:
             a tuple of (state event_ids, auth event_ids)
+
+        Raises:
+            InvalidResponseError: if fields in the response have the wrong type.
         """
         result = await self.transport_layer.get_room_state_ids(
             destination, room_id, event_id=event_id
@@ -416,7 +419,7 @@ class FederationClient(FederationBase):
         if not isinstance(state_event_ids, list) or not isinstance(
             auth_event_ids, list
         ):
-            raise Exception("invalid response from /state_ids")
+            raise InvalidResponseError("invalid response from /state_ids")
 
         return state_event_ids, auth_event_ids