From 427c16ba69b55ef00ff77f612d573f9e46c4d652 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=89ric=20Falconnier?= Date: Tue, 10 Dec 2024 15:03:55 +0100 Subject: [PATCH] Fix monolith catalogs archiving --- zentral/contrib/monolith/repository_backends/base.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/zentral/contrib/monolith/repository_backends/base.py b/zentral/contrib/monolith/repository_backends/base.py index 806e43bb91..e57b9b9686 100644 --- a/zentral/contrib/monolith/repository_backends/base.py +++ b/zentral/contrib/monolith/repository_backends/base.py @@ -257,7 +257,7 @@ def sync_catalogs(self, event_request=None): # archive old catalogs for c in (Catalog.objects.annotate(pkginfo_count=Count("pkginfo", filter=Q(pkginfo__archived_at__isnull=True))) - .filter(archived_at__isnull=True, pkginfo_count=0) + .filter(repository=self.repository, archived_at__isnull=True, pkginfo_count=0) .exclude(pk__in=found_catalog_pks)): self._archive_catalog(c, audit_callback) # update repository