feat(tasks): split list/detail endpoints + add updated_at recency sort#183
Merged
Conversation
GET /tasks now returns TaskSummaryOut (no history), skipping the two
extra SELECT queries that history + responsibilities required. An optional
?terminal=bool query param filters to active or terminal tasks only.
GET /tasks/{id} is unchanged — full TaskOut with history.
The dashboard's _sort_key drops history-based recency (slug/id is the
tiebreaker now) and the detail pane fetches the full task on demand via
GET /tasks/{id}, caching the result until the next refresh.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Stamps every task mutation (any field change or history append/update)
with an ISO-8601 updated_at via a _save_task() helper in the service.
Both GET /tasks (TaskSummaryOut) and GET /tasks/{id} (TaskOut) expose
the field. The dashboard's _sort_key gains a third tier that sorts most
recently updated tasks first within each (terminal, turn) group.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
tildesrc
pushed a commit
that referenced
this pull request
Jun 26, 2026
…dated_at) Merge origin/main (#183): list_tasks now uses list_tasks_summary (lighter query without full history). Combined with our asyncio.to_thread offload so the DB query still doesn't block the event loop. Co-Authored-By: Claude Sonnet 4.6 <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.
Summary
GET /tasks→list[TaskSummaryOut]: cheap list endpoint returning only tasks-table fields (no history), with an optional?terminal=boolfilterGET /tasks/{id}→TaskOut: full detail endpoint with history (was previously the only endpoint)updated_at: ISO-8601 timestamp stamped by the task service on every mutation (field change, history append/update); exposed on both response types; the dashboard's sort uses it for recency (most recently updated first within each tier)ed8efc0b01acadds theupdated_atcolumn to thetasktableDetails
GET /tasksuses SQLAlchemynoload()to skip the history and responsibility joins entirely — two fewer SELECTs per task. The dashboard detail pane fetches the full task viaGET /tasks/{id}on demand (cached per refresh cycle in_task_detail_cache).The
_sort_keyin the dashboard now has four tiers: non-terminal first, user-turn first, most-recently-updated first (negative timestamp), then slug/id for stability.🤖 Generated with Claude Code