Skip to content

Count the tools the container actually starts - #42

Merged
peopleworks merged 1 commit into
mainfrom
dockerfile-tool-count
Aug 5, 2026
Merged

Count the tools the container actually starts#42
peopleworks merged 1 commit into
mainfrom
dockerfile-tool-count

Conversation

@peopleworks

Copy link
Copy Markdown
Owner

One-line comment fix. The Dockerfile claimed seven of the nine tools never open a socket; it has been ten tools since write_report shipped in 0.4.0, and eight of them never open one — only check_paraphrase and measure_predictability can, both opt-in.

Noticed while checking why Glama still lists nine tools after a sync: its metadata comes from the repository and refreshes immediately, but the tool list requires rebuilding and starting the container, which lags. The build spec needs no change — the Dockerfile builds from source, so the rebuild will find all ten.

This comment is read by people deciding whether to trust a container that analyses student coursework.

🤖 Generated with Claude Code

The file said seven of nine. It has been ten since write_report shipped, and only
check_paraphrase and measure_predictability can open a socket at all — both opt-in.

This comment is read by people deciding whether to trust a container that analyses
student coursework, so a stale count in it costs more than it looks.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
@peopleworks
peopleworks merged commit 2e0f9c1 into main Aug 5, 2026
4 checks passed
peopleworks added a commit that referenced this pull request Aug 10, 2026
The second reviewer returned DO NOT SHIP with five reproducible findings. All
five were confirmed by test before being fixed, and all five failed first.

**An image is a request.** Escaping the angle bracket blocks raw HTML and does
nothing to `![alt](url)`. The page's own last line says nothing here was
uploaded anywhere; a report that fetches a pixel from somebody else's host the
moment a teacher pastes it into the LMS has broken that sentence, and the fetch
carries the moment they opened it. Escaping the opening bracket covers images
and links both.

**An asterisk captured the report's own prose.** The signal row is the matched
text followed by the report's `*→ suggestion*`, so one asterisk from the
document paired with the report's marker: emphasis opened at the document's
character and closed at the report's, swallowing the explanation into the
document's content, and the matched character vanished. That is issue #37's
third item, deferred as cosmetic two commits ago and demonstrably not cosmetic.

Fixing it needed the order reversed. Resolving the escapes and then escaping for
HTML puts a live asterisk back before the emphasis pass runs, so the two are now
one pass, and an escaped asterisk returns as `&#42;` — a literal asterisk to
every renderer, exactly as `&lt;` is a literal bracket, and not a character the
emphasis pass can see.

`_` and `` ` `` are deliberately left alone: neither can pair with a marker this
report writes on the same line, so the worst they do is italicise a document's
own text, and escaping them would put a backslash in front of the underscore in
every filename a teacher reads.

**Three more values reaching the page unescaped.** The analysed language, which
`Analyze` takes from its caller and the MCP server takes as free text from a
model; `GeneratedOn` and `EngineVersion`, public settable strings on the same
record whose `DocumentName` was already routed. A newline in either forged a
second heading in the report's own voice.

**`Cell` trimmed the evidence.** A rule whose regex includes the surrounding
spaces matches them, and they are part of the span in the document. Dropped, on
the page whose claim is that it reproduces what the document said.

The cost is one backslash in the raw Markdown of a real report — `cites \[3]` —
which the HTML resolves back to `[3]`, with no stray backslash anywhere on the
page. Checked by reading the generated report, not only the assertions.

The reviewer also confirmed the ordering against every edge asked for, and
100,000 findings sorted and truncated in 41 ms.

Five new tests, 361 green.

Co-Authored-By: Claude Opus 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