summary refs log tree commit diff
path: root/synapse/notifier.py
diff options
context:
space:
mode:
authorErik Johnston <erik@matrix.org>2018-09-19 11:05:21 +0100
committerErik Johnston <erik@matrix.org>2018-09-19 11:07:29 +0100
commit9407bcf37a99ebb72eef73e19632cdcf5964c968 (patch)
tree43baf821e36043fc99f85b950c0be277da74f13c /synapse/notifier.py
parentRun canceller first to allow it to generate correct error (diff)
downloadsynapse-9407bcf37a99ebb72eef73e19632cdcf5964c968.tar.xz
Replace custom DeferredTimeoutError with defer.TimeoutError
Diffstat (limited to 'synapse/notifier.py')
-rw-r--r--synapse/notifier.py5
1 files changed, 2 insertions, 3 deletions
diff --git a/synapse/notifier.py b/synapse/notifier.py
index 2d683718fb..2e7525b7d2 100644
--- a/synapse/notifier.py
+++ b/synapse/notifier.py
@@ -26,7 +26,6 @@ from synapse.handlers.presence import format_user_presence_state
 from synapse.metrics import LaterGauge
 from synapse.types import StreamToken
 from synapse.util.async_helpers import (
-    DeferredTimeoutError,
     ObservableDeferred,
     timeout_deferred,
 )
@@ -354,7 +353,7 @@ class Notifier(object):
                     # Update the prev_token to the current_token since nothing
                     # has happened between the old prev_token and the current_token
                     prev_token = current_token
-                except DeferredTimeoutError:
+                except defer.TimeoutError:
                     break
                 except defer.CancelledError:
                     break
@@ -568,7 +567,7 @@ class Notifier(object):
             try:
                 with PreserveLoggingContext():
                     yield listener.deferred
-            except DeferredTimeoutError:
+            except defer.TimeoutError:
                 break
             except defer.CancelledError:
                 break