Skip to content

Conversation

@reivilibre
Copy link
Contributor

Fixes: #13417

@reivilibre reivilibre force-pushed the rei/purge_shortcut_0 branch from 34bc286 to bdab99f Compare October 23, 2025 11:39
@reivilibre reivilibre marked this pull request as ready for review October 23, 2025 16:40
@reivilibre reivilibre requested a review from a team as a code owner October 23, 2025 16:40
Comment on lines 252 to 256
logger.info(
"[purge] found %i events before cutoff, of which %i can be deleted",
len(event_rows),
sum(1 for e in event_rows if e[1]),
)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems like we can also return early if there are 0 events which can be deleted.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

We can skip a lot of database operations in purge_history if we have no events to purge

3 participants