mirror of
https://github.com/MBombeck/HealthLog.git
synced 2026-11-09 13:01:00 +00:00
Every briefing reader serves `dailyBriefing` only when the payload's `briefingGeneratedAt` falls on the reader's today. The demo seed wrote the comprehensive payload without that stamp and without the language tag, so on a fresh seed the advisor read returned no briefing, the dashboard snapshot stayed "preparing", and a warm was enqueued that can only fail against the placeholder key. The /insights card sat empty while the hero said "Updated today". The seed now writes the cache the way a generation does: the payload stamped through `withBriefingGeneratedAt`, the cache stamp from the same instant, and the `en` tag. The baked paragraph drops its "Good morning" opener, since the hero already greets by the hour. The hero's freshness caption dates the subtitle, so it now shows only when the subtitle is a briefing. The cache stamp also moves when a warm keeps yesterday's text, which the read then withholds; the caption then sat under the generic fallback sentence. `seed()` is exported behind a main-module guard, and an integration test runs the real seed and reads its output back through the advisor read, the dashboard snapshot, the status cards and the period narratives.