line_counter.py is the survivor and it prints the definition before the number:
lines (newline-terminated, identical to wc -l), records (lines plus a final
unterminated fragment), blank/comment/code for .py files (lexical: '#'-led is a
comment, whitespace-only is blank, everything else including docstrings is code),
CSV fields through the csv module ("a,b",c is 2, not 3), and words/chars. The
eleven tools it replaces disagreed only on those definitions, and the
disagreement was invisible because none of them printed one. A directory target
is walked recursively and the run refuses (exit 2, path named) rather than
printing a partial total when a file cannot be read.
Retired, and where each behaviour went:
count_python.py file/line walk -> `line_counter.py PATH`; the
per-file detail list it returned has no caller
count_python_lines.py code/comment/blank breakdown -> PATH report
py_loc.py same breakdown, same key names
loc_counter.py same breakdown; its argparse surface goes with it
linecount_pycount.py totals -> lines/records keys, its code count -> `code`
code_stats.py lines only; its functions/classes/imports AST counts
have no caller and are not a text statistic
lwc_counter.py -> `--words` (lines, words, chars)
text_stats.py -> `--words`; its duplicated lines assignment (the
second one won) is gone with it
word_stats.py -> `--words`; unique/top-5 tables have no caller
file_stats.py -> `--words`
file_analyzer.py -> `--words`; its size_bytes is `wc -c`
quick_stats.py -> `--words`; bytes is `wc -c`; unique/top-5 retired
wordcount.py -> `--words` (its JSON envelope is not kept)
word_counter.py -> `--words`
word_counter_simple.py -> `--words`
word-counter.py -> `--words`
wordfreq.py -> `--words`; frequency table retired, no caller
word_freq.py -> `--words`; frequency table retired, no caller
Retired in the same commit because each graded a tool that no longer exists:
test_linecount.py, test_text_stats.py, verify_lines.py, verify_lwc.py,
verify_wordcount.py, verify_word_freq.sh, check_word_count_report.py
verify_line_counter.sh is repaired rather than deleted. It pinned
/root/.hermes/wizard-outputs/spark and "Total lines: 5587" -- a figure belonging
to the 65-line tool last held at 7359bce that 6b5197b had already replaced -- and
read rc 1 at the opening rev. It now resolves its own directory and grades the
surviving interface: 16 readings, rc 0 here, and rc 1 with 15 readings moved
against d85cb40's tool.
test_line_counter.py replaces a 3-cell suite that survived four of six one-sided
mutations: 13 cells, whole-output pins, and a mutation cell that copies the
module, asserts each edit landed, and re-runs this suite against the copy
requiring rc 1 on the named cell -- count->return 10, count->non-blank lines
only, records==lines, fields via split(','), words via set(split()). Five
mutants, five killed. Against d85cb40's tool the same suite reads 0/13, rc 1.
Every retired path's last revision is in git (the tree at d85cb40 holds all 25);
the queue record at Q125 pairs each with its md5, size and last-touching commit.
tools/path_claim_baseline.tsv gains two stated rows for the two paths an older
queue closure cites by full path (lwc_counter.py, verify_lwc.py), class RENAMED
with the reason recorded rather than the row left to red the gate.
Files: wizard-work/spark/line_counter.py, test_line_counter.py,
verify_line_counter.sh (repaired), README.md, VERIFICATION.md, 25 deletions,
tools/path_claim_baseline.tsv.
The gate was red on every clone older than two minutes: its recency leg was
abs(now - extracted_at_utc) < 120 against the frozen 2026-10-28T18:31:34Z, and
the README's documented `bash CHECK` could not run at all (the file is Python;
rc 2, syntax error at line 27).
- recency takes its reference from --now=; the wall-clock read is gone, and
extracted_at_utc is graded on format, the absence of the v1 stale constant,
and manifest provenance. No reference -> one SKIP line, gate still decides.
- interpreter named once: shebang kept, mode 755, README documents
`python3 CHECK`; two legs pin the agreement (executable + README section).
- --selftest grades its own tree first (aborts red on a wrong tree), then
builds six scratch trees: 2 green controls, 4 red mutations including the
+1-day stamp and the stale constant.
Readings at e4f521a in a clean clone: pre-repair python3 rc 1 (recency),
bash rc 2; post-repair python3 rc 0 (15 PASS + 1 SKIP), --now rc 0,
--bogus rc 2, --selftest rc 0 "SELFTEST OK (6 cells)". Independent
reproduction: wizard-outputs/volt/verify_q122.py, 15 PASS, rc 0.
Volt's Q123 escalated instead of deciding whether WIZARDS-TABLE.md gains the working
lanes or check-ins must be signed by a wizard handle. Ruled: lanes sign as themselves.
- WIZARDS-TABLE.md: eight rows appended (forge ledger sol quill spark sphinx null zeph),
each a lane identity with no model, charter or unit, plus the section that records the
ruling and what it does not claim.
- tools/checkin_baseline.tsv: the 2026-10-27-forge.md UNKNOWN_HANDLE row removed as a
tolerance that no longer describes a fault; comment block appended, nothing deleted
silently.
- Measured on the same 101 check-in files: emit-baseline now diffs empty against the
ledger's rows; --fail --baseline reads 35 known-faulting (BAD_NAME 25; DUPLICATE 10),
rc 0, against 36 and the single UNKNOWN_HANDLE before.
- Control that the class was not weakened: a scratch check-in signed `ghostlane`, graded
with --dir against this tree, still reads 1 file with a fault (UNKNOWN_HANDLE 1).
- tools/verify.py --repo .: 8 legs, 8 pass, gate: OK.
Closure record at the foot of WORK-QUEUE.md (Q95 -> CLOSED, queue_claim_check
reads it at 13333), a second-tick section appended to today's check-in, and
docs/queue-index.md re-rendered with the committed tools/queue_index.py.
Repo gate after the previous commit: 8 of 8 legs pass, rc 0.
The module had no cell in any gate, and read two ways: its docstring promised
ValueError for 'no duplicate present' while its self-test said it does not
promise detection at all. Measured at 95e4962: every array of length n+1 over
1..n for n=1..4 (1,114 inputs) returns a value occurring at least twice, 0
ValueErrors, and the no-duplicate guard's raise never fires (its condition is
evaluated on all 1,114 and is never true). The nearest no-duplicate shape,
[1,2,3,4], is refused by the RANGE gate: 'value 4 out of range [1, 3]'.
- find_duplicate.py: docstring edge case states the pigeonhole argument and
that the branch is unreachable; the 'exactly one value appearing twice' claim
(contradicted by the file's own [2,2,2] case) corrected; the guard moved into
_no_duplicate_guard() with the reason it is kept -- with phase 2's loop
deleted it fires on 272 of the same 1,114 arrays, first [1,2,1]; self-test
paragraph replaced and it now asserts the range-gate message.
- test_find_duplicate.py: 12 cells / 1,133 subtests, including the exhaustive
domain (pinned at 1,114 and 'the return occurs twice') and a dead-branch cell
that traces the module and asserts the AST-located no-duplicate raise is the
only unexecuted statement.
- Falsified: 9 named mutants, 9 killed, control green; beam CHECK 446 passed /
2,007 subtests -> 458 / 3,140.
- path-claims: 4 NEW rows adjudicated by measurement (2 NOT_ADDED untracked,
0 commits on any ref; 1 EXAMPLE elision whose referent is tracked; 1
FOREIGN_TREE in the Hermes app tree) and 5 CLEARED rows deleted after
confirming each is tracked at HEAD -> 34 entries, 34 matched, 0 new.
- checkin: 2026-10-27-forge.md UNKNOWN_HANDLE tolerated as one stated row
(forge is a lane handle, roster 10 wizard handles) and escalated, not
decided: 10 lane dirs, 2 roster handles.
- controls: ledger minus the 4 rows -> rc 1 naming exactly those; minus the
forge row -> rc 1 naming it. selftests 31/31 and 36/36. verify.py 8/8 pass.