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

Fix a bug in the background task for purging chain cover #9583

Merged
merged 2 commits into from
Mar 10, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions changelog.d/9583.bugfix
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Purge chain cover indexes for events that were purged prior to Synapse v1.29.0.
2 changes: 1 addition & 1 deletion synapse/storage/databases/main/events_bg_updates.py
Original file line number Diff line number Diff line change
Expand Up @@ -969,7 +969,7 @@ def purged_chain_cover_txn(txn) -> int:
event_id = ""
for event_id, chain_id, sequence_number, has_event in rows:
if not has_event:
unreferenced_event_ids.append(event_id)
unreferenced_event_ids.append((event_id,))
unreferenced_chain_id_tuples.append((chain_id, sequence_number))

# Delete the unreferenced auth chains from event_auth_chain_links and
Expand Down