CodeIssuesPull RequestsActionsSecurityInsights
✨ AI
More
Settings

feat(status): REPORTING_EPOCH — launch day becomes a one-env-var event #5553

MergedXSccantynz wants to mergefeat/reporting-epochmainopened 6d ago
ccantynzcommented 6d ago

Implements the owner's reporting policy ("accurate honest reporting starts once we are customer ready — the truth always wins") as a single switch:

  • REPORTING_EPOCH (ISO date) is the date /status measures from. Uptime windows clamp to it — "90d uptime" over 18 recorded days is 100%-of-18-days, never a claim about the other 72 (effectiveWindowMs, floored at 1h so a just-set epoch can't zero the denominator). Incidents fully before the epoch leave both the math and the history table (open incidents always count). Days-since caps at the epoch's age. The measurement explainer prints the actual date.
  • Unset, it falls back to the incident ledger's birth (2026-08-09) — nothing changes today, and no figure ever claims time nobody was recording. Garbage values fall back rather than silently measuring from 1970.

At customer-launch: set REPORTING_EPOCH=<launch date> in /opt/gluecron/.env, deploy, and the page starts the clean era — build-time history excluded, honestly labeled.

Three new tests pin the clamp, the floor, and the fallback chain. Typecheck clean; status suites 35 pass; design gate green.

ccantynzAI Reviewcommented 6d ago

AI Triage

(no summary)

Priority: medium Risk area: mixed

Suggested labels: (no label suggestions) Suggested reviewers: (no reviewer suggestions)

Suggestions only — nothing has been applied. The PR author stays in control.

gluecron[bot]🤖 botAI Reviewcommented 6d ago

AI review unavailable

The platform's AI balance is exhausted, so AI generation is temporarily unavailable. Nothing was lost. You can queue this as a repair for the internal agent from the repository's Health page, or try again once the balance is restored. The PR is otherwise unchanged.

Cross-repo impact

See what breaks downstream if this PR merges.

Analyze →
⮌ Merged

This pull request was merged into main.

c comment · e edit title · m merge · a approve · r request changes · ? shortcuts