Loading issues
Remaining scope of PAR-192 after the DORA dashboard shipped (tesks-ui/app/(app)/w/[workspace]/analytics/page.tsx + lib/sql/analytics.ts getDora + AnalyticsCharts). The issue-delivery metrics — the part that distinguishes this from usage/billing reporting (PAR-203) — are not built:
lib/sql/analytics.ts (only getDora today) with these; respect RBAC (who can see workspace analytics).AnalyticsCharts components + analytics-page sections (recharts already in use).issue_event rows where kind='status' (there's no dedicated history table). Decide: derive from issue_event (cheaper, lossy if events were ever pruned) vs add a status_history table written on state change. Needed for accurate per-status lead/aging.Complete. Beyond the earlier throughput/cycle-time/status-aging, this adds:
reopened issue_event is now emitted on completed→open transitions (tesks cc2f7b6, tested), and the analytics page shows a Churn card (reopened/90d + % of completions) + a weekly reopened chart.getActiveSprintBurndown) as a line chart.Shipped tesks-ui c0a38d7 and browser-verified in the seeded harness (Churn card, reopened chart, and the Sprint-1 burndown curve all render). Closing PAR-212.
Progress shipped (
tesks-ui 7229393): throughput (completed/week + 90d), cycle time (median created→done + weekly trend), and status aging (open issues by current state with median time-in-state, derived from the lastissue_event kind='status'). NewgetFlowDAL,ThroughputChart/CycleTimeChart, and a "Delivery flow" section + aging table on/analytics. Typecheck clean.Still remaining on this issue:
completed_atis nulled on reopen so reopens aren't distinguishable, and per-status durations can only be approximated fromissue_event. Decide derive-from-events vs astatus_historytable.