Skip to content
This repository was archived by the owner on Apr 26, 2024. It is now read-only.

Commit 634359b

Browse files
authored
Update docstring to clarify that get_partial_state_events_batch does not just give you completely arbitrary partial-state events. (#14417)
1 parent 64dd8a9 commit 634359b

File tree

2 files changed

+10
-1
lines changed

2 files changed

+10
-1
lines changed

changelog.d/14417.misc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Update docstring to clarify that `get_partial_state_events_batch` does not just give you completely arbitrary partial-state events.

synapse/storage/databases/main/events_worker.py

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2228,7 +2228,15 @@ async def is_partial_state_event(self, event_id: str) -> bool:
22282228
return result is not None
22292229

22302230
async def get_partial_state_events_batch(self, room_id: str) -> List[str]:
2231-
"""Get a list of events in the given room that have partial state"""
2231+
"""
2232+
Get a list of events in the given room that:
2233+
- have partial state; and
2234+
- are ready to be resynced (because they have no prev_events that are
2235+
partial-stated)
2236+
2237+
See the docstring on `_get_partial_state_events_batch_txn` for more
2238+
information.
2239+
"""
22322240
return await self.db_pool.runInteraction(
22332241
"get_partial_state_events_batch",
22342242
self._get_partial_state_events_batch_txn,

0 commit comments

Comments
 (0)