fix(workouts): hold training load through unscored days

A day without a stored training impulse was read as a rest day, so a
watch left off or a nightly run that had not happened yet pulled
fitness and fatigue toward zero. Such a day is now not rated: the
averages hold through it, the series marks it, and the card says how
many of the last 42 days were rated. A scored day of 0 stays rest. The
figures describe the last stored day rather than always yesterday.
This commit is contained in:
Marc-André Bombeck committed 2026-10-21 23:09:09 +02:00
1 parent 2723ac5b98
commit 99dfd68aad
15 files changed
+145 -38

No files matched your search

+21 -4
View File
@@ -49454,7 +49454,8 @@ components:
const: ok
asOf:
type: string
description: The last scored UTC day the figures describe.
description: "The last UTC day with a stored impulse, at most yesterday: a nightly run that has not happened yet never
reads as a rest day."
ctl:
type: number
description: "Fitness: 42-day exponentially weighted TRIMP."
@@ -49472,6 +49473,15 @@ components:
type: integer
minimum: -9007199254740991
maximum: 9007199254740991
recentRatedDays:
type: integer
minimum: -9007199254740991
maximum: 9007199254740991
description: Days of the trailing `recentDays` (42, or fewer when covered less) with a stored impulse.
recentDays:
type: integer
minimum: -9007199254740991
maximum: 9007199254740991
warmingUp:
type: boolean
description: "True below 42 covered days: both averages start at zero."
@@ -49488,11 +49498,16 @@ components:
type: number
tsb:
type: number
rated:
type: boolean
description: "False for a day without a stored impulse (never scored): the averages held through it rather than counting
it as rest."
required:
- day
- ctl
- atl
- tsb
- rated
additionalProperties: false
description: The trailing 90 days, oldest first; `tsb` is form going into the day.
required:
@@ -49503,6 +49518,8 @@ components:
- tsb
- daysCovered
- trainingDays
- recentRatedDays
- recentDays
- warmingUp
- series
additionalProperties: false
@@ -49530,9 +49547,9 @@ components:
- daysCovered
- trainingDays
additionalProperties: false
description: "v1.44 — the fitness-fatigue model over the stored daily heart-rate training impulse (Banister TRIMP; a day
without a stored impulse counts as rest). Needs 28 days and three training days. TRIMP units: comparable with
the person's own past only."
description: "v1.44 — the fitness-fatigue model over the stored daily heart-rate training impulse (Banister TRIMP; a
scored day without training is 0, a day without a stored impulse is not rated and the averages hold through it).
Needs 28 days and three training days. TRIMP units: comparable with the person's own past only."
GetWorkoutResponse:
type: object
properties: