Repository navigation
test(copy,site): keep locale copy free of small slips (#226) - #249
Merged
juancguerrerodev merged 8 commits intoDec 6, 2026
Merged
Conversation
10 of 16 tasks
Contributor
|
Ready to merge once the pull request template is filled in, including the "I read and ran everything" box (details on #234). 🦀 |
juancguerrerodev
force-pushed
the
test/copy-hygiene-226
branch
from
December 6, 2026 07:57
84a226b to
2dc1e3a
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #226
Small slips in copy are easy to make and hard to see in review: a double space, a space at the end of a string, three
dots instead of the ellipsis character the rest of the copy uses, or a Spanish question with no opening mark.
What this PR does
describe("copy hygiene")block topackages/copy/test/copy.test.tswith one small check per slip, each firsttested on made-up strings: no two spaces in a row; no space, tab or line break at the start or end of a value; no
...(the copy uses the one-character ellipsis everywhere today); and, ines-419.jsononly, the number of openingquestion marks equals the number of closing ones, and likewise for exclamations. The same four checks then run over
every value in
packages/copy/locales/en.jsonandes-419.json, naming the key in each failure.apps/site/test/locales.test.tsfor the website's locale files, as a small copy of thechecks there (the site does not depend on
@hermit/copy).Line breaks inside a value are fine; only the start and the end are checked. The placeholders are not text, so a value
like
{count} {unit}is fine.Verification note
The double space check was proven on a real file: adding a double space to
common.retryinpackages/copy/locales/en.jsonmade the test fail naming that key, and the change was undone. No locale file changes in this pull request, because no
check found a real slip in any of the four files.
On my Windows checkout the full site suite also shows one pre-existing failure in
test/badges.test.ts(a badge SVGhash), reproduced on the clean tree without this change; the locale tests themselves pass.
How to check
Pull request template
What and why
Closes #226.
Adds copy hygiene checks over both locale sets: double spaces, edge whitespace, three dots, and Spanish opening marks.
Vision fit
Principle 5, Spanish and English first-class: both locales are held to the same small slips by test.
Non-negotiables
Checklist
acceptedproposal.pnpm check:privacy,pnpm typecheck,pnpm lint,pnpm testandnode scripts/guard/check.mjs --patterns scripts/guard/patterns.txt. Gate note: privacy and guard pass on this checkout today; the rest was run per package as listed under AI agents, not as one root gate on this Windows machine, where unrelated pre-existing failures appear in the site badges, the devices table and mobile source scans.packages/copy, in es-419 and en, with matching keys and placeholders, and no em or en dashes.Model path
packages/model,agent,skillsoreval, the prompt, the router, tool descriptions, normalizers, examples or the model file.Screenshots
New dependencies and network calls
None. No new dependency and no new network call.
AI agents
What was run: pnpm --filter @hermit/copy test (29/29); site locales test (13/13); copy and site typecheck; eslint on the changed tests.