Skip to content

ci(frontend): validate translation keys - #161

Merged
TNT-Likely merged 1 commit into
mainfrom
codex/i18n-key-validation
Sep 28, 2026
Merged

TNT-Likely merged 1 commit into
mainfrom
codex/i18n-key-validation

Conversation

@TNT-Likely

Copy link
Copy Markdown
Owner

Background

Missing i18n resource paths currently fall back to rendering the raw key. The existing check only detects untranslated literals, so incorrect namespace paths and scoped dynamic prefixes can reach users.

Changes

  • Extend the TypeScript AST check to resolve translation namespaces, aliases, scoped wrappers, static keys, and dynamic key prefixes against both locale catalogs.
  • Add positive and negative fixtures covering the two failure modes found in the recent translation audit.
  • Add a lightweight pull-request workflow limited to relevant TypeScript and translation changes; it uses pnpm caching and runs only the i18n check.

Validation

  • pnpm check:i18n — passed for 105 migrated files.
  • pnpm exec vitest run — 30 files and 84 tests passed.
  • pnpm build — passed.
  • .venv/bin/python -m pytest tests/ -x -q — 808 passed, 3 skipped.
  • .venv/bin/python -m pytest packages/marketdata/tests -q — 188 passed.
  • git diff --check — passed.

Boundaries and risks

  • Fully runtime-generated keys without a static prefix remain outside static validation.
  • The workflow runs only for pull requests touching relevant TypeScript, resource, checker, or fixture files.

Follow-up

  • None.

@TNT-Likely
TNT-Likely merged commit 545641b into main Sep 28, 2026
1 check passed
@TNT-Likely
TNT-Likely deleted the codex/i18n-key-validation branch September 28, 2026 14:50
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