feat(web): order dashboard specs by created_at, newest first#30
Merged
Conversation
…aged agents and skills
The web overview listed specs alphabetically by feature name. Order them by spec.json created_at descending instead, so the most recently created spec sits at the top of the panel. created_at is an RFC3339 UTC string (always …Z, written once at `spec init`), so a lexical compare is chronological. Equal created_at — and unreadable specs, whose created_at is empty — fall back to feature name ascending for a stable, total order. All three surfaces (API, TUI, CLI) go through LoadOverview, so they stay consistent. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
The web dashboard's spec list was ordered alphabetically by feature name. Order it by
spec.jsoncreated_atdescending instead, so the most recently created spec sits at the top of the panel.All three surfaces (API
GET /api/overview, TUI, CLI) go throughsession.LoadOverview, so they stay consistent — the change lives in one place.Why
created_atis the true creation instant, stamped once atcsdd spec init(time.Now().UTC().Format("2006-01-02T15:04:05Z")) and never rewritten. It is an RFC3339 UTC string (always…Z, fixed width), so a lexical string compare is chronological — no parsing needed. Filesystem mtime was rejected as a source: it means "last modified", changes on every edit, and is reset bygit clone/checkout.How
In
LoadOverview, after building the spec cards,sort.SlicebyCreatedAtdescending. Equalcreated_at— and unreadable specs, whosecreated_atis empty (sorts last) — fall back to feature-name ascending for a stable, total order.Tests
TestOverviewSpecsSortedByCreatedAtDesc— three specs whose dates diverge from alphabetical order (alpha=Jan, beta=Jun, gamma=Mar →beta, gamma, alpha); catches any regression to name-sorting.TestOverviewSpecsCreatedAtTieBreaksByName— equal-created_attie and the empty/unreadable case in one fixture.TestOverviewupdated to assert newest-first ordering.code-reviewerran: no Blockers (APPROVE WITH NITS).Verification
🤖 Generated with Claude Code