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

Commit 172ce29

Browse files
authored
Fix spurious warning when fetching state after a missing prev event (#13258)
1 parent a6895dd commit 172ce29

File tree

2 files changed

+4
-0
lines changed

2 files changed

+4
-0
lines changed

changelog.d/13258.misc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Fix spurious warning when fetching state after a missing prev event.

synapse/handlers/federation_event.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1037,6 +1037,9 @@ async def _get_state_ids_after_missing_prev_event(
10371037
# XXX: this doesn't sound right? it means that we'll end up with incomplete
10381038
# state.
10391039
failed_to_fetch = desired_events - event_metadata.keys()
1040+
# `event_id` could be missing from `event_metadata` because it's not necessarily
1041+
# a state event. We've already checked that we've fetched it above.
1042+
failed_to_fetch.discard(event_id)
10401043
if failed_to_fetch:
10411044
logger.warning(
10421045
"Failed to fetch missing state events for %s %s",

0 commit comments

Comments
 (0)