Compare commits

1 Commits
Author SHA1 Message Date
clawbot 37972fc413 Name the reaper's hard delete in the event body comments (closes #455)
check / check (push) Successful in 3m16s
The comments on eventBodyQuery and on its reaped-event test credited
the deleted_at predicate with refusing a reaped event. The retention
reaper deletes event rows outright, so a reaped event is simply gone;
nothing soft-deletes an event, so the predicate excludes nothing today
and the test's soft-delete case only pins it.

Model: opus-5-5
2026-10-02 17:03:58 +00:00
+5 -4
View File
@@ -405,10 +405,11 @@ func TestHandleEventBodyDownload_UnknownEvent404s(t *testing.T) {
// route. The body is read in one query before any header is // route. The body is read in one query before any header is
// written, so a reaped event cannot produce a partial download: // written, so a reaped event cannot produce a partial download:
// it is a clean 404 with no Content-Length and no // it is a clean 404 with no Content-Length and no
// Content-Disposition. Both removals the codebase performs are // Content-Disposition. The reaper deletes event rows outright,
// covered — the reaper hard-deletes, and a soft-deleted row is // which is the "hard deleted" case. The "soft deleted" case
// excluded by the query's own deleted_at predicate rather than // covers a row no code produces today: it only pins the query's
// by GORM's default scope, which Raw bypasses. // own deleted_at predicate, the soft-delete condition Raw would
// otherwise skip.
func TestHandleEventBodyDownload_ReapedEvent404s(t *testing.T) { func TestHandleEventBodyDownload_ReapedEvent404s(t *testing.T) {
t.Parallel() t.Parallel()