Skip to content

Commit ded8d9d

Browse files
committed
feat: bugfix issue 1421
1 parent 6c53621 commit ded8d9d

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

aperag/tasks/reconciler.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -409,11 +409,12 @@ def reconcile_all(self):
409409
def _get_summaries_needing_reconciliation(self, session: Session) -> List[CollectionSummary]:
410410
"""
411411
Get all collection summaries that need reconciliation
412+
Only select summaries with PENDING status and version mismatch
412413
"""
413414
stmt = select(CollectionSummary).where(
414-
or_(
415+
and_(
415416
CollectionSummary.version != CollectionSummary.observed_version,
416-
CollectionSummary.status != CollectionSummaryStatus.GENERATING,
417+
CollectionSummary.status == CollectionSummaryStatus.PENDING,
417418
)
418419
)
419420
result = session.execute(stmt)

0 commit comments

Comments
 (0)