Skip to content

limit 60: a deleted or edited thought sidecar no longer goes unread - #65

Merged
githubscum merged 1 commit into
mainfrom
lotor-lane/thought-sidecar-check
Oct 22, 2026
Merged

githubscum merged 1 commit into
mainfrom
lotor-lane/thought-sidecar-check

Conversation

@githubscum

Copy link
Copy Markdown
Owner

WO

KNOWN-LIMITS 60, reader half. Thought sidecars were bound to receipts by digest, but nothing ever read one back. A deleted or edited sidecar was silent: you could detect it in principle, and in practice nobody did.

The v3 queue is still waiting on rulings (V3-02 question, hook-core ruling for V3-03/04, V3-07/V3-08 home), so this run took a KNOWN-LIMITS item. It is non-core: src/views/ plus a new test, and nothing under the protected directories.

What changed

  • src/views/thoughts.js (new): checkThoughtSidecars(entries, home) returns { rows, summary }. Each thoughts/1 binding gets one of six statuses: match, mismatch (with the hash it found), missing, none-expected (count 0, where ingest writes no file), or malformed (bad count or digest, so nothing was expected anywhere). Any file in <home>/thoughts/ that no receipt expects is reported as orphan. The check hashes raw bytes and never throws. For missing it does not guess whether a crash or a deletion caused it.
  • test/views-thought-sidecars.test.js (new, 9 tests).
  • KNOWN-LIMITS.md: dated NARROWED paragraph on limit 60 that names what is still open.

Tested

  • npm test: 1065/1065 (main is 1056, so +9).
  • Probed read-only against a real store with 36,433 entries in about 2.3 s: 3,292 match, 0 mismatch, 4 none-expected, 0 orphan, 0 malformed, and 1 missing: session 5742c2aa, subsession 0, 15 thoughts. The receipt is on the chain and the sidecar is gone. This is a live instance of limit 60, and the check correctly declines to say which of the two causes produced it.

Eval

None of E1-E6. This is R1 completeness and legibility work that sits next to v3, not a v3 rung.

Executors

All code was written off-meter. session.model was read on the chain:

  • glm-5.3-flash, first pass (seq 36408).
  • glm-5.3-flash, fix pass (seq 36413). Both GLM passes shipped a test that failed. Each time the cause was the same: the tests share a temp home, so an orphan file stayed in scope for later tests. The second pass also claimed it had updated all seven summary literals and missed one.
  • minimax-m3, under the lane's fallback rule (seq 36430). It fixed the remaining two failures.

The orchestrator re-read every artifact and ran the suite.

What a reviewer should doubt

  1. The mutation probe did not run. I tried to flip the digest comparison temporarily, and the session's permission layer denied the edit. The mismatch test does assert both the status and that the reported hash is over the bytes now on disk, but no one has watched the suite fail against a broken comparison.
  2. Tests depend on order. They share one temp home in sequence, the same harness style as the existing ingest sidecar test. Two tests filter out the leftover orphan instead of isolating it.
  3. This is a function, not a surface. No CLI, MCP tool or view calls it yet. Wiring it into verify or the chapters/since views is the obvious next step, but it would touch more than this WO should.
  4. Orphans are detected only against the entries passed in. Pass a filtered chain and every other session's sidecar shows up as an orphan. The probe passed the full chain.
  5. The executor receipt for seq 36413 lists both absolute and relative paths for each file it touched, plus one failed edit on a misspelled sibling path (assistant-receipts) that wrote nothing. That is more live evidence for limit 75/76: one edited file no longer counts twice in touched #62.

checkThoughtSidecars reports each thoughts/1 binding as match, mismatch,
missing, none-expected or malformed, and unexpected files as orphan.
First real-store run: 3292 match, 1 missing. Executors glm-5.3-flash
and minimax-m3 (fallback), receipts seq 36408, 36413, 36430.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
githubscum added a commit that referenced this pull request Oct 22, 2026
The KNOWN-LIMITS numbering test requires contiguous entries, so numbers
follow the merge order #65, #66, #64, #63, #60, #62, #61, #67, #68, #69,
#70, #71: #62 takes 75, #61 takes 76, this PR takes 77. Every citation on
this branch moves with it (KNOWN-LIMITS.md heading and the limit 53 note,
src/views/matcher-history.js header, test/matcher-history.test.js comment).

On this branch alone the numbering test reports 75 and 76 missing; that
clears once #62 and #61 are on main.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
githubscum added a commit that referenced this pull request Oct 22, 2026
The KNOWN-LIMITS numbering test requires contiguous entries, so numbers
follow the merge order #65, #66, #64, #63, #60, #62, #61, #67, #68, #69,
#70, #71: #62 takes 75, #61 takes 76, #67 takes 77, this PR takes 78.
Every citation on this branch moves with it: KNOWN-LIMITS.md heading,
CHANGELOG.md, docs/receipt-coverage.md, and the V3-03 proposal note. The
staged .patch carries no limit number and is unchanged.

On this branch alone the numbering test reports 75, 76 and 77 missing;
that clears once #62, #61 and #67 are on main.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@githubscum
githubscum merged commit 8d6f7aa into main Oct 22, 2026
githubscum added a commit that referenced this pull request Oct 22, 2026
The KNOWN-LIMITS numbering test requires contiguous entries, so numbers
follow the merge order #65, #66, #64, #63, #60, #62, #61, #67, #68, #69,
this branch moves with it (KNOWN-LIMITS.md heading and the limit 53 note,
src/views/matcher-history.js header, test/matcher-history.test.js comment).

On this branch alone the numbering test reports 75 and 76 missing; that
clears once #62 and #61 are on main.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant