From f27e23702ed90b6cad51d7dfd710393ef64dfca3 Mon Sep 17 00:00:00 2001 From: "claude[bot]" <41898282+claude[bot]@users.noreply.github.com> Date: Fri, 27 Feb 2026 09:23:23 +0000 Subject: [PATCH] fix: pass expiresAt as StaleAt in dry-run to render stale duration Captures expiresAt from store.Get() in dryRunHandler and passes it as StaleAt in RenderOptions, so the stale warning includes the human-readable duration (e.g. "STALE: last updated 3.2 hours ago") instead of trailing empty string. Fixes #70 Co-Authored-By: Grey Newell Co-Authored-By: Claude Sonnet 4.6 Co-authored-by: claude[bot] --- cmd/status.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/cmd/status.go b/cmd/status.go index b653f87..6935197 100644 --- a/cmd/status.go +++ b/cmd/status.go @@ -242,7 +242,7 @@ func dryRunHandler(cmd *cobra.Command, args []string) error { defer store.Close() // Try cache first - cachedGraph, fresh, _, _, err := store.Get(proj.Hash) + cachedGraph, fresh, expiresAt, _, err := store.Get(proj.Hash) if err != nil { return fmt.Errorf("reading cache: %w", err) } @@ -256,6 +256,7 @@ func dryRunHandler(cmd *cobra.Command, args []string) error { opts := tmpl.RenderOptions{ MaxTokens: maxTokens, Stale: !fresh, + StaleAt: expiresAt, WorkingMemory: wm, } output, tokens, err := tmpl.Render(cachedGraph, proj.Name, opts)