refactor(kanban): drop redundant int() in gc_events cutoff

hermes_cli/kanban_db.py:4288 — older_than_seconds is already normalised
with int(...) on the line above the negative check, so the second int()
in the cutoff expression is a no-op. Sibling gc_worker_logs already
subtracts the bare value (float cutoff for st_mtime), so nothing to change
there. No behaviour change.

Gate finding: spec-D fold item 4.
This commit is contained in:
kshitijk4poor
2026-09-22 12:36:55 +05:30
committed by kshitij
parent 9134d3228f
commit 1be926dbcd

View File

@@ -4285,7 +4285,7 @@ def gc_events(conn: sqlite3.Connection, *, older_than_seconds: int = 30 * 24 * 3
older_than_seconds = int(older_than_seconds)
if older_than_seconds < 0:
raise ValueError(_NEGATIVE_RETENTION_MSG.format(older_than_seconds))
cutoff = int(time.time()) - int(older_than_seconds)
cutoff = int(time.time()) - older_than_seconds
with write_txn(conn):
cur = conn.execute(
"DELETE FROM task_events WHERE created_at < ? AND kind != 'decomposed' AND task_id IN "