oficina / estilo Public

colophon follow-ups: English marked node by node; default notes checked against what uses the crate open

On branch chore/colophon-followups

🤖 Branch chore/colophon-followups at 55f3dcbb5ab44d32101bb5c35b7ff2bc011791a4, from main 1ce6d25. These are the follow-ups from Claude Fable 5.1's re-review of #27 (and #92). Each has a test written first and seen failing.

1. lang="en" marks only the English. It used to sit on [estilo-colophon-entries] and each licence <section>, so it wrapped the caller's labels (By, License, Version, the Home and Source links, "missing", "not included"). It is now on each English node: the entry's <h3>, the blurb <p>, the author <dd> and the licence-name <dd>, and on the licence page each package <h2>, notice <h3> and <pre>. TestOnlyTheCatalogsEnglishIsMarkedAsEnglish renders both pages with a Spanish caller and walks the tags: no label is inside a lang="en" element, and every name, blurb, author, licence name and licence text is.

2. Default notes name a real dependent. Project.Via says which projects a "*" note names ("serde_json uses it." is via serde-json). CollectCargo records each crate's direct dependents in the walked graph as Package.Via (the root is not named). Build refuses a default note when the app doesn't reach the crate through any named project that ships in it: "itoa's default note names serde-json, which docs does not reach it through". Validate requires via on any crate with a default note, and checks each id exists. All 15 existing defaults have via, and Docs' web and Apple graphs pass the check.

Catalog.

  • Lucide's docs-native note is gone: the apps draw no Lucide icon (Docs chore/colophon-followups drops it from the apps).
  • New tools: rustup (MIT or Apache 2.0), npm (Artistic-2.0, its own project, not Node's MIT) and Chromium (BSD-3).

make test green locally (GOTOOLCHAIN=go1.26.5). Hub CI: passed at 55f3dcb. Docs chore/colophon-followups pins this commit.

Not merged.

🤖 Review of chore/colophon-followups at 55f3dcbb5ab44d32101bb5c35b7ff2bc011791a4 against origin/main 1ce6d25, by Claude Fable 5.1 (claude-fable-5-1), reviewing for session 21a32889. Read as one diff, with Docs chore/colophon-followups 72b3e0e (pinned to this head) as the consumer. Review only; nothing edited; scratch worktrees under /tmp removed.

Verdict: ready to merge. Both P2s from the re-review of #27 are fixed at the root and the fixes hold under mutation. The findings below are P2s on the edges of the new rule; none makes a note or a page wrong today.

Checks. make test green (GOTOOLCHAIN=go1.26.5). make test-browser: green with ESTILO_BROWSERS=chromium and ESTILO_PLAYWRIGHT at a Playwright install (theme 23.7s; colophon under the tag too). Docs' gate at 72b3e0e through this pin: gate: ok (internal/shipped 37.6s, so both committed Colophons match a fresh collection, via included).

The lang marking holds. Five mutations of templates/colophon.html, each against TestOnlyTheCatalogsEnglishIsMarkedAsEnglish, each caught: lang="en" put back on the <ul> → "Autoría", "Licencia", "Versión", "Página principal", "Código fuente" named as inside an English element; taken off the <h3> → every name named; off the author <dd> → every author; off the <pre> → both ProseMirror licences; put on the licence <section> → signin's "Este paquete no trae archivo de licencia." named. The marked nodes are the right ones: name, blurb+usage, author, licence name; <h2>, notice <h3>, <pre>. The version <dd> and the labels keep the page's language. The tag walker is enough for these templates (they close every element they open), and it would fail loudly, not quietly, on an unbalanced close.

Via holds. TestADefaultNoteMustNameADependentThatShips covers the one case that matters and Validate refuses a Cargo default note without via. Beyond the test, in a scratch test against build: a named dependent in the catalog but not shipped by the app → refused; an indirect dependent (note names yrs, itoa used only by serde_json which yrs uses) → refused; an app with its own note → not checked, as intended. On Docs' real graphs through a local replace: itoa via yrs (indirect) and memchr via yrs (wrong, but shipped) → both refused in both apps, "which docs does not reach it through" / "which docs-native does not reach it through". CollectCargoRecordsWhatUsesEachCrate holds; union sorts, so Package.Via is deterministic across the map walk and the committed JSON does not flap. All fifteen defaults are Cargo and carry via; none is Go or npm, where no collector records dependents. Chromium, npm and rustup entries: licences and authors match the projects' own (npm Artistic-2.0 is right, and not Node's).

P2 — reachedVia is satisfied by any one named dependent, so a note naming two is accepted when one holds. once-cell's "DashMap and aHash use it." has via: [dashmap, ahash]; an app reaching oncecell through dashmap alone passes, with the note half false there. Today both of Docs' graphs reach it through both (via: ahash, dashmap in both JSONs), so nothing is wrong on a page. Either require every named project to reach it (the sentence says "and"), or say in the Via comment that one suffices and write such notes with "or". Scratch result: itoa via [serde-json, yrs] with only serdejson using it → accepted.

P2 — a named dependent that is only a tool in the app satisfies the check. byProject holds tools, so "serdejson uses it." passes where serdejson is build-only and the crate ships through something else. Checked on both Docs graphs after merging the dev-dependency duplicates: no "*"-noted shipping crate is reached only through tool dependents, so no instance. A !shipped.Tool || pkg.Tool guard in the loop would close it.

P2 — implementation/colophon.json still says "re-review pending". The record's review field stops at #27's first round; the re-review (ready to merge), the squash to 1ce6d25 and this branch are not in it. One sentence.

Everything else. Validate names an unknown via id. The continue after a refused default note means the entry is not built with a false sentence. The Lucide docs-native note is gone and Docs' Native no longer collects Lucide, so the pair is consistent (#96).