Expand description
Run-scoped analysis clock.
Churn recency weighting, ownership staleness, and the churn window all need
a “now”. Reading the system clock separately at each of those sites makes
two runs over the same commit disagree: the recency decay is continuous, so
weighted_commits moves every run, and stale_days flips fixed thresholds
(owner-active, drift minimum file age) as the day rolls over. The clock here
resolves once per churn analysis from HEAD’s committer timestamp, so one
commit always yields the same churn-derived numbers on any machine.
FALLOW_CLOCK_EPOCH pins the reference epoch explicitly, for reproducible
builds and for comparing two checkouts against a fixed instant.
Structs§
- Analysis
Clock - The single instant a run measures commit ages and staleness against.
Enums§
- Analysis
Clock Source - Where a run’s reference epoch came from.
Constants§
- CLOCK_
EPOCH_ ENV - Environment override for the run’s reference epoch, in unix seconds.
Functions§
- utc_
date - The UTC calendar date of a unix epoch, as
YYYY-MM-DD. - utc_
midnight_ epoch - Parse an ISO
YYYY-MM-DDdate into the epoch of its UTC midnight. - utc_
timestamp - A unix epoch as an RFC 3339 UTC timestamp,
YYYY-MM-DDTHH:MM:SSZ.