mirror of
https://github.com/block/buzz.git
synced 2026-11-02 23:41:08 +00:00
Three fleet-wide background scans filtered candidates only by communities.archived_at, ignoring the deletion lifecycle (deletion_state / deleted_at) introduced with the community write fence: - list_all_enabled_workflows (cron scheduler input) - query_due_reminders (NIP-ER reminder sweep) - list_large_channel_rosters_needing_reconciliation (roster repair) Each downstream write is already blocked by the universal write-fence trigger, but an unfenced scan re-surfaces a quiescing tenant's rows on every tick, turning the trigger rejection into a recurring background error and wasted work. Gate all three scans on archived_at IS NULL AND deletion_state = 'active' AND deleted_at IS NULL, matching the community_write_allowed predicate used by the ephemeral channel reaper and push-match queue. Adds quiescing-tenant/active-bystander regression tests for each scan, mirroring the existing push-matcher fence tests. Signed-off-by: Logan Johnson <loganj@squareup.com> Co-authored-by: Wakko <wakko@buzz.block.builderlab.xyz>