Alert activity / statistics view #83

Closed
opened 2026-07-18 05:31:43 +00:00 by claude-bot · 1 comment
Contributor

A cheap slice of what v2.0.0's Historical Explorer will eventually do: counts by location, event type, and month, straight off the sent_alerts rows already retained. Delivers "how much weather does this location get" without the full explorer build. Missed because history was deferred wholesale to v2.0.0. Effort S, value Medium — flag against #22 so it's a deliberate down-payment, not a competing implementation.


Filed from the 2026-07-17 codebase audit (docs/.internal/report-2026-07-17.md), finding I-13.

A cheap slice of what v2.0.0's Historical Explorer will eventually do: counts by location, event type, and month, straight off the `sent_alerts` rows already retained. Delivers "how much weather does this location get" without the full explorer build. Missed because history was deferred wholesale to v2.0.0. Effort S, value Medium — flag against #22 so it's a deliberate down-payment, not a competing implementation. --- _Filed from the 2026-07-17 codebase audit (`docs/.internal/report-2026-07-17.md`), finding I-13._
Author
Contributor

Done in #114 (merged). GET /stats ("Activity" nav) shows alert counts off the retained sent_alerts dashboard records: headline totals plus breakdowns by location, event type (top 15 + "other"), and month — restricted to locations the user can see, counting only channel_id IS NULL rows (no per-channel double counting). Month grouping is done in Python for dialect portability. Self-contained stats.html (simple bars, no chart library), graceful empty state, readonly-viewable. Framed in-code as a deliberate down-payment on the v2.0.0 Explorer (#22), not a competing build. 6 tests.

Done in #114 (merged). `GET /stats` ("Activity" nav) shows alert counts off the retained `sent_alerts` dashboard records: headline totals plus breakdowns by location, event type (top 15 + "other"), and month — restricted to locations the user can see, counting only `channel_id IS NULL` rows (no per-channel double counting). Month grouping is done in Python for dialect portability. Self-contained `stats.html` (simple bars, no chart library), graceful empty state, readonly-viewable. Framed in-code as a deliberate down-payment on the v2.0.0 Explorer (#22), not a competing build. 6 tests.
Sign in to join this conversation.
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
rbrooks/WeatherBot#83
No description provided.