Skip to content

fix(core,docs): packed schema, YAML and llms text names only pages that ship (#948) - #963

Merged
jimhoyd merged 5 commits into
mainfrom
claude/packed-text-948
Sep 29, 2026
Merged

jimhoyd merged 5 commits into
mainfrom
claude/packed-text-948

Conversation

@jimhoyd

@jimhoyd jimhoyd commented Sep 29, 2026

Copy link
Copy Markdown
Collaborator

Fixes #948

Packed non-Markdown text (schema descriptions, YAML comments in shipped examples and the starter, and llms-full.txt prose) named docs/*.md pages the package does not ship.

Design: pinned release links, moved by the bump

  • Schemas (schemas/urlcode.schema.json, schemas/requests.schema.json): descriptions now say https://github.com/jimhoyd-com/urlcode/blob/v<version>/docs/X.md. That's what an editor hover shows, and it's the same document the schema URL serves at that tag. The build can't rewrite these because the schema is published by tag URL straight from the committed file, so the pin is committed.
  • release:bump rewrites every github.com/jimhoyd-com/urlcode/(blob|tree)/v<version>/ link in tracked non-Markdown text (json/yaml/yml/txt/toml/html/css). It skips package-lock.json, the llms indexes (which have their own mechanism), and this repository's tests, scripts and workflows. --check fails when one of these links names a version other than the current one.
  • docs/YAML-REFERENCE.md: docs:reference turns each pinned URL in a description into a reference link labelled by its docs path ([docs/HTTP.md]). The link is defined in the page's existing urlcode-current-version block, so on GitHub the page reads as before with working links, and the version still appears only inside the marker block.
  • Examples and starter: the comments in examples/cookbook/urlcode.yaml, examples/cookbook/routes/middleware.yaml and examples/monitoring/prometheus-{rules,scrape}.yaml are pinned. So is starters/default/.github/workflows/urlcode.yml, which linked blob/main/docs/CI.md.
  • llms-full.txt: scripts/build-llms-full.ts (pinDocsMentions) links two kinds of mention of an unshipped page to the release tag: a bare docs/X.md in prose, and a code span that holds only that path. "Shipped" means the docs/ entries in package.json files. It leaves alone links, reference labels, longer code spans and fenced code. On this tree it rewrites 5 prose mentions: SPIKE-DEFAULT-TRUST-MODEL, CAPACITY, SPECIFICATION and YAML-GUIDE.
  • Package audit: packedTextProblems reads every packed file that is neither Markdown nor code (isPackedText), fenced or not. That covers JSON, YAML, TXT including the llms indexes, TOML, HTML, CSS, templates and Makefiles; binary files (NUL byte) are skipped. It fails on two things:
    • a docs/*.md mention of an unshipped page that is not a link label;
    • a blob/main or tree/main link to this repository. A package.json is exempt from this one because a manifest's homepage names the project.
  • docs/DEVELOPMENT-PIPELINE.md describes all of the above.

Not in scope

Evidence

  • npm run verify green, npm run test:package green (Node 26).
  • Budgets after merging main: 1033938 packed / 4093060 unpacked bytes, 528 entries on Node 26. Packed budget 1014 KiB is unchanged (still ~3.5 KiB over Node 24's +800); unpacked raised to 4001 KiB.
  • New tests: packedTextProblems, pinDocsMentions, bump/check of pinned links in a schema and a YAML file (with a test fixture left alone), and a drift case for a stale pin.

🤖 Generated with Claude Code

jimhoyd and others added 2 commits September 29, 2026 14:55
…at ship (#948)

Schema descriptions, example and starter YAML comments now link this
release's blob/v<version>/docs/... copy, which release:bump rewrites in
tracked non-Markdown text and --check holds to the current version.
docs:reference turns those URLs into reference links defined in the
YAML-REFERENCE.md marker block. The llms-full.txt build links bare
docs/X.md mentions of unshipped pages to the release tag. The package
audit reads every other packed text file (packedTextProblems) for
unshipped docs pages and main-branch links.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@jimhoyd
jimhoyd enabled auto-merge (squash) September 29, 2026 20:06
@jimhoyd
jimhoyd merged commit 5f5c6bc into main Sep 29, 2026
25 checks passed
@jimhoyd
jimhoyd deleted the claude/packed-text-948 branch September 29, 2026 21:05
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.

[Bug]: schema descriptions, example YAML comments and llms-full prose still name docs pages the package doesn't ship

1 participant