fix(list): carry projects in the bare-filter catch-all view - #232
Merged
Merged
Conversation
Every named view except inbox returns project rows (#205, #209, #216, #220), but a filter with no view named — `things --area Work`, `things -t urgent` — routes to the internal catch-all view, which was still pinned to `t.type = 0`. An agent sweeping an area that way got none of its projects. The catch-all now uses the same `todoOrProject` set as the named views. `--project` is unaffected in practice: a project has no parent project of its own, so `p.uuid` never matches a project row and the filter still returns a project's contents. Verified against Things.app on 10 Sep 2026 by uuid. For one area the app reports four projects; the CLI returned none before this change and returns the same four uuids after. `--project` still returns zero project rows. Tests cover the widened set, the exclusions that must not widen with it (headings, trashed projects, repeating project templates and their children), and the `--area`/`--tag`/`--project` split. Four existing tests asserted the old to-do-only behaviour and now assert the project rows. Docs drop the exception the paragraph has carried since #220, in SKILL.md, commands.md, agents.md and the README, and name the `--project` case instead. Closes #222
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.
Closes #222
What changed
The internal catch-all view — the one a bare
--project/--area/--tagfilter routes to when no view is named — was still pinned tot.type = 0while every named view exceptinboxhad been widened totodoOrProject(#205, #209, #216, #220). It now uses the same set.--projectis unaffected in practice: a project has no parent project of its own, sop.uuidnever matches a project row and the filter still returns a project's contents. The visible change is for--areaand--tag.Why
An agent sweeping an area with
things --area Work -jgot none of that area's projects, which is exactly the miss #222 describes. Parity with what Things.app shows in the matching list is the project's stated goal.How verified
Measured by uuid against Things.app on 10 Sep 2026. For one area the app reports four projects; the CLI returned zero project rows before this change and returns the same four uuids after.
things --project <uuid> -jstill returns zero project rows.Tests added in
internal/db/tasks_test.gocover the widened set, the--area/--tag/--projectsplit, and the exclusions that must not widen with it — headings, trashed projects, repeating project templates and the to-dos inside them. Four existing tests asserted the old to-do-only behaviour and now assert the project rows: two area filters, the catch-all grouping order, and the CLI-level default-view test.make testandmake lintare clean.Docs
The paragraph naming the bare-filter exception was rewritten once, in
internal/skill/SKILL.md,docs/content/commands.md,docs/content/agents.mdand the README. It now states the--projectcase rather than a whole-view exception.