Repository navigation
v1.24.0 — new.py, rotate.py, --open in: lines
What
scripts/new.py— the deterministic half ofnew: profile walk (nearest wins, spelled from the repo root), sibling list (never decided), a registry with only template keys,_log.mdwith the R1 stub, doc 01's headings in the profile's language; runsauditon the result. Refuses if any of its three files exists, rejects bad slugs and multi-line titles, exits non-zero when the result does not parse.scripts/rotate.py— executes the_log.mdrotation--rotate-planonly printed. Needs the rotation stub open (· rotateas the action field); keeps_log.md.origuntil the archive and the kept part reassemble the original byte for byte; re-reads the log right before replacing it; fsyncs; keeps permissions; refuses a symlink; flags a leftover archive from an interrupted run.rotate_plansplit into a structured plan and its printer;--rotate-planoutput byte-identical to v1.23.0 on five real logs. Nested HTML comments in the log template no longer count as rounds.--openin:lines — under each open entry, the doc spans that cite it (from--doc-index), grouped by file, sure citations beforemaybe;--compactprints a count and every item line fits 80 characters;--jsongainssections.- Return contract (
references/parallel.md, templates,agents/spec-*.md) — file runners keep every finding in the delivery and return a summary of at most 40 lines withoverflow:; the merge reads the delivery.claudesubagents stay read-only and return everything as text.agy's JSON is redirected to the delivery file by the main session. Rule 1: a subagent writes nothing in the set except its own delivery.
Measured on real sets
- Largest real log (192 KB, 2888 lines): rotated to 273 lines + a 2625-line archive; preamble + archive body + kept part == original.
--openon a 307 KB registry: 38 KB within:lines (31.8 KB without), 9.7 KB with--compact.new.pyon a real repo layout: the new set audits clean.
Review
Reviewed by a second model (Claude Opus). Blocker: new.py overwrote an existing _log.md when _facts.yml was missing. That and seven other bugs are fixed, each with a test that fails without the fix. Two more found while re-testing on real data (--open grew to 49 KB with headings in in: lines; --compact item lines at 123 characters) are fixed and tested too.
Verification
test_audit.py 331/331 across 69 fixtures; test_rotate.py 15/15 and test_new.py 12/12 (new); ship, facts, triage, render, sync green.
Release: v1.24.0 (README row and clone pin bumped). Merge with a merge commit.