We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 7e40330 commit e1aed0fCopy full SHA for e1aed0f
kinto/core/storage/postgresql/__init__.py
@@ -635,6 +635,7 @@ def purge_deleted(
635
{resource_name_filter}
636
AND rn > :max_retained
637
)
638
+ RETURNING 1
639
"""
640
641
id_field = id_field or self.id_field
@@ -660,7 +661,7 @@ def purge_deleted(
660
661
safeholders["conditions_filter"] = "AND as_epoch(last_modified) < :before"
662
placeholders["before"] = before
663
- with self.client.connect() as conn:
664
+ with self.client.connect(force_commit=True) as conn:
665
result = conn.execute(sa.text(delete_tombstones.format_map(safeholders)), placeholders)
666
deleted = result.rowcount
667
0 commit comments