Use org.matrix.msc3871.gaps

This commit is contained in:
Eric Eastwood
2026-03-26 15:33:42 -05:00
parent d9c9706c05
commit 0d25dcd15d
2 changed files with 3 additions and 3 deletions
+1 -1
View File
@@ -861,7 +861,7 @@ async def encode_messages_response(
bundle_aggregations=get_messages_result.bundled_aggregations,
)
),
"gaps": [
"org.matrix.msc3871.gaps": [
{
"prev_pagination_token": await get_messages_result.start_token.copy_and_replace(
StreamKeyType.ROOM, gap.prev_token
+2 -2
View File
@@ -2530,7 +2530,7 @@ class RoomMessageListTestCase(RoomBase):
# Make sure the gaps are correct
actual_gaps = [
event_id_to_message_map.get(gap["event_id"], gap["event_id"])
for gap in channel.json_body["gaps"]
for gap in channel.json_body["org.matrix.msc3871.gaps"]
]
expected_gaps = expected_messages
# We only need to assert that gaps are in the list (the order doesn't matter)
@@ -2540,7 +2540,7 @@ class RoomMessageListTestCase(RoomBase):
exact=True,
)
# Ensure that the tokens point to the correct positions
for gap in channel.json_body["gaps"]:
for gap in channel.json_body["org.matrix.msc3871.gaps"]:
event_room_stream_token = self.get_success(
self.store.get_topological_token_for_event(gap["event_id"])
)