1
0

Assertion on bug

This commit is contained in:
Olivier Wilkinson (reivilibre)
2020-08-26 21:01:06 +01:00
parent 16eec5cbfa
commit 92517e95fc

View File

@@ -506,15 +506,17 @@ class PerDestinationQueue(object):
# - don't need to worry about rejected events as we do not actively
# forward received events over federation.
events = await self._store.get_events_as_list(event_ids)
if not events:
raise AssertionError(
"No events retrieved when we asked for %r. "
"This should not happen." % event_ids
)
# zip them together with their stream orderings
catch_up_pdus = [
(event, event.internal_metadata.stream_ordering) for event in events
]
if not catch_up_pdus:
break
success = await self._transaction_manager.send_new_transaction(
self._destination, catch_up_pdus, []
)