diff options
author | Richard van der Hoff <github@rvanderhoff.org.uk> | 2018-01-31 22:17:38 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-01-31 22:17:38 +0100 |
commit | 518a74586c04f04219b52b21bc1c11e1f85589d0 (patch) | |
tree | d5358edad183a9726a18291373925e5ce3ab89ea /synapse | |
parent | Merge pull request #2833 from matrix-org/rav/pusher_hacks (diff) | |
parent | Improve exception handling in persist_event (diff) | |
download | synapse-518a74586c04f04219b52b21bc1c11e1f85589d0.tar.xz |
Merge pull request #2834 from matrix-org/rav/better_persist_event_exception_handling
Improve exception handling in persist_event
Diffstat (limited to 'synapse')
-rw-r--r-- | synapse/storage/events.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/synapse/storage/events.py b/synapse/storage/events.py index 7a9cd3ec90..33fccfa7a8 100644 --- a/synapse/storage/events.py +++ b/synapse/storage/events.py @@ -110,7 +110,7 @@ class _EventPeristenceQueue(object): end_item.events_and_contexts.extend(events_and_contexts) return end_item.deferred.observe() - deferred = ObservableDeferred(defer.Deferred()) + deferred = ObservableDeferred(defer.Deferred(), consumeErrors=True) queue.append(self._EventPersistQueueItem( events_and_contexts=events_and_contexts, @@ -152,8 +152,8 @@ class _EventPeristenceQueue(object): try: ret = yield per_item_callback(item) item.deferred.callback(ret) - except Exception as e: - item.deferred.errback(e) + except Exception: + item.deferred.errback() finally: queue = self._event_persist_queues.pop(room_id, None) if queue: |