diff --git a/AGENTS.md b/AGENTS.md index 06b1c8ca..ee700c08 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -11,3 +11,4 @@ Decisions live in `docs/decisions.md`: - comprehension floor: the 2026-09-25 four-seat score is the ratchet, and 0.1.0 waits on what caps it - larv-review: a re-entered loop takes a fresh round cap - vocabulary: the concept words are defined under `CLAUDE.md` → "Vocabulary" and cited by a bare link +- loop-claude: a CR-only README.md is reported at line 1 diff --git a/bin/loop-claude b/bin/loop-claude index 754d09a9..56d2a54f 100755 --- a/bin/loop-claude +++ b/bin/loop-claude @@ -166,7 +166,8 @@ def read_premises(root): except OSError as failure: sys.exit(f"README.md in {root}: {failure.strerror} - no premises.") except UnicodeDecodeError as failure: - sys.exit(f"README.md is not UTF-8 on line {failure.object[:failure.start].count(b'\n') + 1} - no premises.") + line = failure.object.count(b"\n", 0, failure.start) + 1 + sys.exit(f"README.md is not UTF-8 on line {line} - no premises.") for name in ("Goals", "Audience"): bodies = found.get(name, []) if not bodies: diff --git a/docs/decisions.md b/docs/decisions.md index 3fe13416..9764e8a5 100644 --- a/docs/decisions.md +++ b/docs/decisions.md @@ -35,3 +35,7 @@ ## loop-claude: a reload into an older file is unsupported 2026-09-26, lilleman. Serves goal 4. A running loop whose `bin/loop-claude` on disk is rolled back to a version with an older handover dies with a traceback in that older file, which this version cannot change; the human who rolled it back reruns `loop-claude `. Valid while nobody but the developer runs it: other team members running it while it is still developed reopens this. + +## loop-claude: a CR-only README.md is reported at line 1 + +2026-09-26, larv-review. Serves goal 4. The line of a non-UTF-8 byte counts `\n`, so a file with classic-Mac `\r` endings reports line 1 whatever line an editor shows; no machine the audience runs writes such a file. Valid while the audience is the author's own machines.