atproto relay implementation in zig zlay.waow.tech
9
fork

Configure Feed

Select the types of activity you want to include in your feed.

fix: cast aggregate query results to bigint for pg.zig compatibility

SUM() and COUNT() return numeric in postgres, which pg.zig's strict
type checking can't read into i64. explicit ::bigint casts fix the
panic in getStatus.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

zzstoatzz a916f9c4 cb50f5b4

+1 -1
+1 -1
src/backfill.zig
··· 339 339 var total_imported: i64 = 0; 340 340 { 341 341 var row = (self.db.rowUnsafe( 342 - "SELECT COUNT(*), COUNT(completed_at), COALESCE(SUM(imported_count), 0) FROM backfill_progress", 342 + "SELECT COUNT(*)::bigint, COUNT(completed_at)::bigint, COALESCE(SUM(imported_count), 0)::bigint FROM backfill_progress", 343 343 .{}, 344 344 ) catch null) orelse null; 345 345 if (row) |*r| {