summary refs log tree commit diff
path: root/synapse/rest/media/v1
diff options
context:
space:
mode:
authorErik Johnston <erik@matrix.org>2017-06-13 10:23:14 +0100
committerErik Johnston <erik@matrix.org>2017-06-13 10:23:14 +0100
commit48d29494165f2b12e2d2b6206766828e2a542ef4 (patch)
tree23881ca5116a402b95ce7249521e2531b870fe8c /synapse/rest/media/v1
parentMerge pull request #2266 from matrix-org/erikj/host_in_room (diff)
downloadsynapse-48d29494165f2b12e2d2b6206766828e2a542ef4.tar.xz
Throw exception when not retrying when downloading media
Diffstat (limited to 'synapse/rest/media/v1')
-rw-r--r--synapse/rest/media/v1/media_repository.py1
1 files changed, 1 insertions, 0 deletions
diff --git a/synapse/rest/media/v1/media_repository.py b/synapse/rest/media/v1/media_repository.py
index caca96c222..bae2b4c757 100644
--- a/synapse/rest/media/v1/media_repository.py
+++ b/synapse/rest/media/v1/media_repository.py
@@ -184,6 +184,7 @@ class MediaRepository(object):
                     raise
                 except NotRetryingDestination:
                     logger.warn("Not retrying destination %r", server_name)
+                    raise SynapseError(502, "Failed to fetch remote media")
                 except Exception:
                     logger.exception("Failed to fetch remote media %s/%s",
                                      server_name, media_id)