Skip to content

Fix Remover.have_new_references() to ignore objects missing in storage

We don’t clean up the object_references table when we remove an object. Remover.have_new_references() uses object_find_recent_references() to detect if any new references have been added since we started the removal operation. But stale entries interfered with this detection.

Therefore we have to filter objects missing from storage when looking for new references. As this problem also occurs while determining unremovable objects, we factor out the logic in swh.alter.utils.get_filtered_objects().

Bonus point: we have removed a hard coded limit!

Co-authored with Nicolas Dandrimont.

Merge request reports

Loading