Skip to content

Space the units in an agent's age - #8

Merged
dsaad68 merged 1 commit into
mainfrom
fix/age-format
Aug 24, 2026
Merged

Space the units in an agent's age#8
dsaad68 merged 1 commit into
mainfrom
fix/age-format

Conversation

@dsaad68

@dsaad68 dsaad68 commented Aug 24, 2026

Copy link
Copy Markdown
Owner

28h51m30s is one word to read before you can see the number that matters.
Spaced, it is three.

before   finished a turn · 28h51m30s ago
after    finished a turn · 28h 51m 30s ago

Go's Duration.String() also keeps trailing zeros, so a record exactly two
hours old rendered 2h0m0s. Empty units are dropped now — 2h, and 1h 1s
where there are no whole minutes.

Put in internal/agent beside Words rather than in the picker, because the
agents listing formats the same thing and was already drifting: it called
Round(time.Second).String() separately, so the CLI and the box could disagree
about the same record. Both now share one formatter.

Tested across the range, including the ordering property — units descend and
never repeat, with gaps allowed, since 1h 1s is correct when there are no
whole minutes.

🤖 Generated with Claude Code

"28h51m30s" is one word to read before you can see the number that matters.
Spaced, it is three: "28h 51m 30s".

Go's Duration.String() also keeps trailing zeros, so a record exactly two hours
old rendered "2h0m0s". Empty units are dropped now — "2h", and "1h 1s" where
there are no whole minutes.

Put in internal/agent beside Words rather than in the picker, because the
`agents` listing formats the same thing and was already drifting: it called
Round(time.Second).String() separately, so the CLI and the box could disagree
about the same record.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
@dsaad68
dsaad68 merged commit 0fdcc2d into main Aug 24, 2026
5 checks passed
@dsaad68
dsaad68 deleted the fix/age-format branch August 24, 2026 20:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant