feat(read): project-view children dissolve to flat items[] (read-shape doctrine PR 2) - #376
Merged
Merged
Conversation
…e doctrine PR 2)
Dissolve the project-view's unheaded anytime/upcoming/someday buckets AND the
per-heading stage sub-buckets into ONE flat `items[]` in project index order
(read-shape doctrine §3.12). Second of five PRs.
- data.view.items: all LIVE children (unheaded + headed), index order, each row
carrying stage (kept — stage-mixed) + when, and each HEADED row carrying its
heading ref (flat title + project-scoped headingUuid, kept in compact). A
heading's membership is now a per-row attribute, reconstructed by filtering
items on heading.
- headings[]: the memberless live-heading catalog [{heading:{uuid,title,archived?}}]
(incl. empty + archived-unswept headings). PR 3 unwraps it, merges swept
archived headings, and dissolves logbookHeadings.
- logbook / logbookHeadings / advisories / card node: unchanged this PR.
- TTY byte-stable: verified byte-identical on a rich fixture (before/after
capture) + the full render suite. The library keeps its structured render
grouping (owns the clock + todayIndex) to project the GUI layout; only the
wire flattened.
src/read/project-view.ts (adds items[]), src/read/shape.ts (shapeProjectView).
Tests: shape.test.ts, e2e.test.ts, stage.test.ts, mcp/server.test.ts. 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
This was referenced Aug 3, 2026
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.
Second of five sequential PRs implementing the read-shape doctrine (
docs/design/read-shape-doctrine.md§3.12). Branched from PR 1 (#375).What changed (breaking, ALPHA)
The
project show/get_projectview's live child buckets dissolve into one flatitems[]— a heading's membership is a per-row attribute, not a bucket.data.view.items— every LIVE child (unheaded and headed) in projectindexorder. Each row keepsstage(the list is stage-mixed) andwhen; each headed row carries itsheadingref (flat title + project-scopedheadingUuidwhen the title would not round-trip, kept even in compact). Unheaded rows omitheading. Reconstruct a heading's members by filteringitemsonheading.anytime/upcoming/somedaybuckets and the per-heading stage sub-buckets are gone from the wire.headings[]is now the memberless live-heading catalog[{heading:{uuid,title,archived?}}](incl. empty + archived-unswept headings). PR 3 unwraps it, merges swept archived headings, and dissolveslogbookHeadings.logbook,logbookHeadings, the advisories, and the card node.TTY byte-stability
project showoutput is byte-for-byte identical — verified by a before/after capture on a maximally-rich fixture (loose + headed children across every stage, closed-unswept, logged, archived-unswept + swept headings, stranded open child) across all flag combos, plus the full render suite. The library retains its structured render grouping (it owns the clock +todayIndex) to project the GUI-faithful layout; only the wire flattened.Verification
npm run checkgreen (typecheck + oxlint + fmt:check + 2311 tests). New tests: unit shape (flat items[] + memberless catalog + heading refs), CLI e2e wire-shape regression, per-row stage property, MCPget_project.🤖 Generated with Claude Code