changed weight reminder schedule
Deploy / deploy-dev (push) Successful in 2m32s
Deploy / deploy-prod (push) Skipped

This commit is contained in:
blaisadmin
2026-09-05 23:23:56 -04:00
parent 5abc7f6174
commit 856753b012
9 changed files with 84 additions and 25 deletions
+8 -2
View File
@@ -163,12 +163,18 @@ npm run worker
### Overdue weight emails
The worker checks every five minutes for living birds with no new weight entry in
The worker checks once per calendar day for living birds with no new weight entry in
48 hours. Each accepted owner, assistant, or caregiver receives one email per flock
listing all birds due for a reminder. Pending invitees and viewers are excluded.
Reminders repeat every 48 hours while overdue; adding a new weight restarts the
Reminders repeat daily while overdue; adding a new weight restarts the
48-hour clock. Birds without weights use their profile creation time.
Scheduling matches hatch-day reminders: a check 15 seconds after worker startup,
then hourly, with one queued job per local date. There is no fixed morning send
time. Both use `MILESTONE_REMINDER_TIME_ZONE` (default `America/New_York`).
Delivery tracking uses local calendar dates, including daylight-saving changes.
Deploying this change removes the old five-minute Redis schedule.
The clock uses the weight entry's creation timestamp, since the measurement date
has no time of day. Editing an existing entry does not restart the clock; entering
a historical weight does. Memorialized birds are excluded.