summary refs log tree commit diff
diff options
context:
space:
mode:
authorRichard van der Hoff <1389908+richvdh@users.noreply.github.com>2020-05-26 11:42:22 +0100
committerGitHub <noreply@github.com>2020-05-26 11:42:22 +0100
commit04729b86f8e2d83002aad2d2298c3fc7e4836b2f (patch)
treed9ef76f712b60f155c28d18661bb3e2cb7e73360
parentFix recording of federation stream token (#7564) (diff)
downloadsynapse-04729b86f8e2d83002aad2d2298c3fc7e4836b2f.tar.xz
Fix incorrect exception handling in KeyUploadServlet.on_POST (#7563)
Introduced in #7556
-rw-r--r--changelog.d/7563.misc1
-rw-r--r--synapse/app/generic_worker.py2
2 files changed, 2 insertions, 1 deletions
diff --git a/changelog.d/7563.misc b/changelog.d/7563.misc
new file mode 100644
index 0000000000..ed271f9de8
--- /dev/null
+++ b/changelog.d/7563.misc
@@ -0,0 +1 @@
+Stop logging some expected HTTP request errors as exceptions.
diff --git a/synapse/app/generic_worker.py b/synapse/app/generic_worker.py
index 440341cb3c..5afe52f8d4 100644
--- a/synapse/app/generic_worker.py
+++ b/synapse/app/generic_worker.py
@@ -214,7 +214,7 @@ class KeyUploadServlet(RestServlet):
                     self.main_uri + request.uri.decode("ascii"), body, headers=headers
                 )
             except HttpResponseException as e:
-                raise e.to_synapse() from e
+                raise e.to_synapse_error() from e
             except RequestSendFailed as e:
                 raise SynapseError(502, "Failed to talk to master") from e