feat(read): area-view direct to-dos dissolve to flat items[] (read-shape doctrine PR 4) - #378
Merged
Merged
Conversation
…ape doctrine PR 4) Dissolve the area-view's direct anytime/upcoming/someday buckets into ONE flat items[]; keep projects[] (read-shape doctrine §3.13). Fourth of five PRs. An area has two order axes (project sidebar rank, direct-to-do index), so it keeps two flat lists. - data.view.items: every direct to-do in area index order, each carrying stage (kept — mixed) + when, area dropped. anytime/upcoming/someday gone. - data.view.projects: UNCHANGED (child-project rows, sidebar order, mixed stage). The projects/someday-projects/direct/upcoming/loose render variants are TTY projections of projects[] + items[]. - Per-block caps unchanged: area_limit caps the open/current direct to-dos; the "area" block reports those hidden and the flat items[] drops exactly them (later scheduled/someday rows always ride items[]; --show-later is TTY-only). - TTY + truncation byte-stable (verified byte-identical incl. the area_limit cut). The library keeps its structured direct-to-do grouping for the GUI projection; only the wire flattened. Removed the now-dead rebucketChildren card-bucketing helper (no wire surface has stage/date sub-buckets anymore). src/read/area-view.ts (adds items), src/read/truncation.ts (capAreaSections), src/read/shape.ts (shapeAreaView), src/mcp/server.ts (get_area/get_project descs). Tests: unit shape/truncation, cli e2e/loose/render, mcp. Docs: read-shape-doctrine.md, contract.md, design/contracts.md. No apiVersion/error code change. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01RYbJensXxHpJK1v1VDXYUD
mikegreiling
added a commit
that referenced
this pull request
Aug 5, 2026
… re-audit (#398) * Revert "docs(read): ordering contract + skill sweep for the read-shape doctrine (PR 5) (#379)" This reverts commit debbe6f. * Revert "feat(read): area-view direct to-dos dissolve to flat items[] (read-shape doctrine PR 4) (#378)" This reverts commit 044ffd0. * Revert "feat(read): project-view headings catalog + logbook flatten (read-shape doctrine PR 3) (#377)" This reverts commit 94f1dda. * Revert "feat(read): project-view children dissolve to flat items[] (read-shape doctrine PR 2) (#376)" This reverts commit 57321bc. * Revert "feat(read): today dissolve — flat items[] + meta.counts; badge purge (read-shape doctrine PR 1) (#375)" This reverts commit ce4fa4d. * chore(read): post-revert bookkeeping — CHANGELOG, doctrine status, skill floor Follow-up to the five read-shape doctrine reverts (#375-#379): - CHANGELOG: add a breaking Unreleased entry documenting the wholesale revert and the return to pre-0.13.0 bucketed today/project/area shapes; meta.counts removed. Clean revert, no compat shims (ALPHA-CONTRACT). - docs/design/read-shape-doctrine.md: restored (the PR-1 revert deleted it) with its status changed to REVERTED (dated) — retained as the input to a design re-audit of the read-shape approach. - skills/things-cli/SKILL.md: reconcile the npx floor sentence. The skill again teaches the bucketed read shapes, which 0.13.0 does NOT have; anchor the floor to the skill's publish-stamped version (the release that ships these shapes) instead of the now-false "below 0.13.0" literal. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01C1g2PkB43exMAfFdg6QnMT --------- Co-authored-by: Claude <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.
Fourth of five sequential PRs implementing the read-shape doctrine (
docs/design/read-shape-doctrine.md§3.13). Branched from PR 3 (#377).What changed (breaking, ALPHA)
An area has TWO order axes (project sidebar rank, direct-to-do index), so it keeps two flat lists.
data.view.items— ONE flat list of every direct to-do in areaindexorder, each row carryingstage(KEPT — stage-mixed) andwhen,areadropped (the card states it). Theanytime/upcoming/somedaydirect-to-do buckets are gone. Area direct to-dos are never headed nor project-nested → fully self-describing.data.view.projects— UNCHANGED (child-project rows, sidebar order, mixed-stage, someday/scheduled included). The distinct order axis; theprojects/ someday-projects / direct / upcoming / loose render variants collapse to TTY projections ofprojects[]+items[].project_limitcaps project rows,area_limitcaps the open/current direct to-dos; theareatruncation block reports those hidden, and the flatitems[]drops exactly them (the later scheduled/someday rows always rideitems[]—--show-lateris TTY-only, never gated the wire).TTY + truncation byte-stability
area showoutput AND the truncation blocks are byte-for-byte identical (verified incl. thearea_limitcut on a rich fixture, plus the full render + loose-pseudo-area suites). The library retains its structured direct-to-do grouping for the GUI projection; only the wire flattened. Also removed the now-deadrebucketChildrencard-bucketing helper — no wire surface has stage/date sub-buckets anymore.Verification
npm run checkgreen (typecheck + oxlint + fmt:check + 2313 tests). New/updated tests: unit shape + truncation (capped items[]), CLI e2e wire regression, loose-pseudo-area, MCPget_area.🤖 Generated with Claude Code