Skip to content

Commit e5272b7

Browse files
claude[bot]os-project-managerclaude
authored
docs(skills): name translation-target-unknown an error in the i18n skill (#17946)
Fixes #17787 ## What changed `skills/objectstack-i18n/SKILL.md` :196–:201 — one sentence, re-flowed within its own six lines. It grouped `translation-target-unknown` and `translation-option-key-unknown` under the single word "warnings"; on the tree the first is raised at `error` and fails the run, the second stays a warning. The sentence now names each id with its own severity. No other file is touched. Before (flattened): > `os validate` / `os lint` / `os compile` check this direction and report it as warnings (`translation-target-unknown`, `translation-option-key-unknown`): a key naming an object, field, view, tab, action, param, section, validation rule, app, nav item, dashboard, widget or flow screen that does not exist is listed alongside the names that do. … After (flattened): > `os validate` / `os lint` / `os compile` check this direction: `translation-target-unknown` is an **error** and fails the run; `translation-option-key-unknown` is a warning. A key naming an object, field, view, tab, action, param, section, validation rule, app, nav item, dashboard, widget or flow screen that does not exist is listed alongside the names that do. … The tail of the paragraph (「A bundle keyed to something since renamed still parses — …」) is content-identical; only line breaks moved. ## Severities re-measured on the tree (card acceptance item 2) Measured at `origin/main` `84e6b05` (this branch's base), not against the card: | id | severity on the tree | evidence | |---|---|---| | `translation-target-unknown` | `error` | `packages/lint/src/validate-translation-references.ts` :31 (severity note), :151 `TRANSLATION_TARGET_UNKNOWN_SEVERITY = 'error'`, :155–:156 (field docblock), emitted at :813 and :1265; test `validate-translation-references.test.ts` :306 「raises `translation-target-unknown` at `error`, selectable by its exact id」 | | `translation-option-key-unknown` | `warning` | same file :1210 and :1229 `severity: 'warning'` beside `rule: TRANSLATION_OPTION_KEY_UNKNOWN`; test :327 「leaves `translation-option-key-unknown` at `warning`」 | The card's wording is still current: the option-key rule has not moved since the triage grading. ## Acceptance greps (both directions, this branch at `1974cee`) - `grep -c 'report it as warnings' skills/objectstack-i18n/SKILL.md` → `0` - lit control: `grep -c 'translation-option-key-unknown' skills/objectstack-i18n/SKILL.md` → `1` - `error` inside the same sentence as `translation-target-unknown`: see the flattened "After" sentence above — 「… check this direction: `translation-target-unknown` is an **error** and fails the run; …」 ## Line and token readings for `skills/**` | reading | before (`84e6b05`) | after (`1974cee`) | delta | |---|---|---|---| | `skills/objectstack-i18n/SKILL.md` lines | 494 | 494 | +0 | | `skills/objectstack-i18n/SKILL.md` bytes | 18830 | 18850 | +20 | | `skills/objectstack-i18n/SKILL.md` ratchet tokens (ceil bytes/4) | 4708 (ceiling 6338, headroom 1630) | 4713 (ceiling 6338, headroom 1625) | +5 | | whole package: all `skills/*/SKILL.md` lines summed | 6134 | 6134 | +0 | | whole `skills/objectstack-i18n/` directory lines | 524 | 524 | +0 | | ratchet bundle total (whole shipped tree, tokens) | 139594 | 139599 | +5 | +0 lines is met by re-flowing only the six lines of the edited sentence (new widths 91/81/87/92/88/68; the sentence's own pre-edit maximum was 92, at line 200). Nothing outside the sentence was re-wrapped and no content was deleted to pay for anything. The ratchet prices tokens, not lines; the ceiling is untouched. ## Gates Derived with `node scripts/pm/dispatch-gates.mjs --commands --repo objectstack-ai/objectstack` on `1974cee` (24 commands — the same 24 the dispatch clue list named), each run in the foreground with its exit code captured before any pipe, then reconciled with `--ran`: `24 derived, 24 run, 0 NOT-MEASURED, 0 UNRUN`. | command | exit | |---|---| | `node scripts/check-ci-filter-parity.mjs` | 0 | | `node scripts/check-closing-keyword-parity.mjs` | 0 | | `node scripts/check-closing-keyword-parity.mjs --self-test` | 0 | | `node scripts/check-comment-mask-corpus.mjs` | 0 | | `node scripts/check-doc-route-spelling.mjs --advisory` | 0 | | `node scripts/check-doc-route-spelling.mjs --self-test` | 0 | | `node scripts/check-skills-token-ratchet.mjs` | 0 | | `node scripts/check-skills-token-ratchet.mjs --self-test` | 0 | | `node scripts/report-test-timings.mjs --self-test` | 0 | | `pnpm --filter @objectstack/lint run check:doc-formula-expressions` | 0 | | `pnpm --filter @objectstack/spec run check:skill-docs` | 0 | | `pnpm check:agent-test-spelling` | 0 | | `pnpm check:corpus-claim-drift` | 0 | | `pnpm check:cross-package-test-inputs` | 0 | | `pnpm check:doc-authoring` | 0 | | `pnpm check:driver-memory-census` | 0 | | `pnpm check:nul-bytes` | 0 | | `pnpm check:pm-governed-merges` | 0 | | `pnpm check:refd-timer-probe` | 0 | | `pnpm check:role-word` | 0 | | `pnpm check:skill-compatibility` | 0 | | `pnpm check:skill-frame-sync` | 0 | | `pnpm check:skill-identifier-liveness` | 0 | | `pnpm check:watch-hint-literal` | 0 | - `check:doc-formula-expressions`: the first run exited 3 (`PREREQUISITE NOT MET` — `@objectstack/formula` and `@objectstack/lint` are not built in a fresh worktree), which measures nothing. After `pnpm exec turbo run build --filter=@objectstack/formula --filter=@objectstack/lint` (the remedy the gate itself prescribes; run under `scripts/pm/os-verify-lock.sh`, `VERDICT command-exit 0`) it exited 0. The build left the tree clean (`git status --porcelain` printed nothing). - `check:skill-docs` reads only the SKILL.md frontmatter (the catalog); this body edit moves no generated listing — it reports in sync, nothing regenerated. - Not owed, not run: no workspace package is touched (`skills/` is not one), so there is no dependency-closure build and no package `test` / `typecheck` for this diff. The 14 "pending-changeset" families the derivation lists apply only once a changeset exists; this PR ships none (measured below). ## Changeset: `skip-changeset`, measured `skills/**` reaches customer projects at scaffold time through `packages/create-objectstack/src/skills-install.ts` (`SKILLS_CATALOG = 'objectstack-ai/objectstack/skills'`, pulled from the git catalog by the skills CLI) — not inside any npm tarball. Measurement on `1974cee`: 70 non-private `package.json` manifests under `packages/`, `examples/` and `apps/` (node_modules excluded); 0 whose `files[]` mentions `skills`; positive control: 70 whose `files[]` mentions `dist`. `create-objectstack` itself ships `["dist", "README.md", "CHANGELOG.md"]`. No released package's `files[]` ships this path, so nothing published moves ⇒ `skip-changeset`, applied with the additive labels endpoint and read back. ## Governed surface `skills/**` is governed (AGENTS.md Prime Directive #14). This PR stays a draft: no seat flips it ready, queues it, arms auto-merge or submits a review — the maintainer lands it by hand. ## Acceptance notes - Other carriers of the literal id, re-checked on `84e6b05` with `git grep -n 'translation-target-unknown' origin/main -- skills content docs examples`: `examples/app-showcase/test/seed.test.ts:94` (already says the rule fails) and `docs/audits/2026-07-app-metadata-reference-integrity-assessment.md:143` (a dated audit table of counts). Neither is false; nothing filed. - Open PRs: one was opened after the dispatch's serial reading (#17937); its file list does not touch `skills/`. - noted, not filed: the skill nowhere else states what an `error`-severity finding does to a run, which is why the sentence spells out "fails the run" instead of relying on the severity word alone. No carrier. ## 维护者速读(草稿) **改了什么**:`skills/objectstack-i18n/SKILL.md` 里的一句话(第 196–201 行)。原句把 `translation-target-unknown` 与 `translation-option-key-unknown` 一起称为「warnings」;现在分别写明:前者是 **error**,会让 `os validate` / `os lint` / `os compile` 这次运行失败;后者仍是 warning。只改这一句,文件行数 494 → 494。 **为什么改**:PR #17777 已把 `translation-target-unknown` 提到 error 级(`packages/lint/src/validate-translation-references.ts`),技能文件却还说它是 warning。技能是 AI 作者最先读、而且不会去复核的那份说明——写错等于教 AI 把一个会让构建失败的问题当成可忽略的提示。 **风险与代价(含回滚)**:纯文档改动,不发布任何 npm 包(实测 70 个非 private 包的 `files[]` 无一包含 `skills/`),无运行时影响。技能 token 棘轮 +5(上限 6338,余量 1625),不动上限。回滚 = revert 这一个 commit。 **席位意见**:(留空,待席位定稿) **你要做的**:确认这句表述与你对两个规则严重度的预期一致,然后人工合并(受管面 `skills/**`,不走队列)。若 `translation-option-key-unknown` 日后也提级,这句话需要再改一次。 --- _Generated by [Claude Code](https://claude.ai/code/session_01DAcomhvR9kKizeYgg89Vo8)_ Co-authored-by: os-project-manager <pm@objectstack.ai> Co-authored-by: Claude <noreply@anthropic.com>
1 parent 884e834 commit e5272b7

1 file changed

Lines changed: 6 additions & 6 deletions

File tree

‎skills/objectstack-i18n/SKILL.md‎

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -193,12 +193,12 @@ for `options: [{ value: 'direct_mail', label: 'Direct Mail' }]` write
193193
`options: { direct_mail: '直邮' }` — both `'Direct Mail'` and `'direct-mail'`
194194
parse, ship, and resolve to nothing.
195195

196-
`os validate` / `os lint` / `os compile` check this direction and report it as
197-
warnings (`translation-target-unknown`, `translation-option-key-unknown`): a key
198-
naming an object, field, view, tab, action, param, section, validation rule, app,
199-
nav item, dashboard, widget or flow screen that does not exist is listed alongside
200-
the names that do. A bundle keyed to something since renamed still parses — the label just
201-
renders silently in its source locale while every neighbouring one resolves.
196+
`os validate` / `os lint` / `os compile` check this direction: `translation-target-unknown`
197+
is an **error** and fails the run; `translation-option-key-unknown` is a warning.
198+
A key naming an object, field, view, tab, action, param, section, validation rule, app,
199+
nav item, dashboard, widget or flow screen that does not exist is listed alongside the names
200+
that do. A bundle keyed to something since renamed still parses — the label just renders
201+
silently in its source locale while every neighbouring one resolves.
202202

203203
---
204204

0 commit comments

Comments
 (0)