fix(i18n): translate locale fallback strings#3004
Conversation
|
Warning Review limit reached
More reviews will be available in 49 minutes and 26 seconds. Learn how PR review limits work. Your organization has run out of usage credits. Purchase more in the billing tab. ⌛ How to resolve this issue?After more reviews become available, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans include higher PR review limits than trial, open-source, and free plans. In all cases, reviews become available again over time. During sustained high-volume PR review activity, CodeRabbit may temporarily slow when the next review becomes available. Please see our Fair Usage Limits Policy for further information. ℹ️ Review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (92)
Comment |
…erage # Conflicts: # app/src/lib/i18n/chunks/ar-1.ts # app/src/lib/i18n/chunks/ar-4.ts # app/src/lib/i18n/chunks/bn-1.ts # app/src/lib/i18n/chunks/bn-4.ts # app/src/lib/i18n/chunks/de-1.ts # app/src/lib/i18n/chunks/de-4.ts # app/src/lib/i18n/chunks/es-1.ts # app/src/lib/i18n/chunks/es-4.ts # app/src/lib/i18n/chunks/fr-1.ts # app/src/lib/i18n/chunks/fr-4.ts # app/src/lib/i18n/chunks/hi-1.ts # app/src/lib/i18n/chunks/hi-4.ts # app/src/lib/i18n/chunks/id-1.ts # app/src/lib/i18n/chunks/it-1.ts # app/src/lib/i18n/chunks/it-4.ts # app/src/lib/i18n/chunks/ko-1.ts # app/src/lib/i18n/chunks/ko-4.ts # app/src/lib/i18n/chunks/pt-1.ts # app/src/lib/i18n/chunks/pt-4.ts # app/src/lib/i18n/chunks/ru-1.ts # app/src/lib/i18n/chunks/ru-4.ts # app/src/lib/i18n/chunks/zh-CN-1.ts # app/src/lib/i18n/chunks/zh-CN-4.ts
…nslate leftovers
- Merge chunks/<locale>-{1..5}.ts into a single app/src/lib/i18n/<locale>.ts
per locale (en.ts remains the source of truth). Removes 70 chunk files,
the en.ts<->chunks drift guard, per-chunk drift detection, and the one-off
mirror helper.
- Rewrite scripts/i18n-coverage.ts, apply-i18n-translations.ts and the Vitest
coverage test for the single-file model.
- Translate remaining English-identical UI strings into all 13 non-English
locales (~2,300 strings); preserve placeholders, brand names, model IDs,
paths, commands and other technical literals.
- Update CLAUDE.md / AGENTS.md / .claude/memory.md i18n conventions.
Parity unchanged (missing=0, extra=0 all locales); untranslated counts drop
sharply, residue is intentional technical literals.
…etector The coverage gate only flags values byte-identical to the current en string, so it was blind to 'stale English' — values translated from an older en string that since changed (e.g. settings.search.allowedSitesHint) and English prose that simply differs from current en. - Add scripts/i18n-find-english.ts (pnpm i18n:english:check): script-coverage detection for non-Latin locales, English-only function-word detection for Latin locales (vocabulary-ratio is unreliable due to cognates), with a reviewed INTENTIONAL_ENGLISH allowlist for brand names / commands / paths / units / cognates. Exits non-zero on any non-allowlisted English so it can gate CI. - Translate the genuine English/stale-English values it surfaced across all 13 locales (mcp.health.*, mcp.inventory.*, memorySources URLs, Knowledge Graph Centrality, Knowledge vaults, Configuration assistant, Invalid JSON, etc.). - Document the new gate in CLAUDE.md. Detector now reports 0 unexpected English for every locale.
…erage # Conflicts: # app/src/lib/i18n/chunks/ar-2.ts # app/src/lib/i18n/chunks/bn-2.ts # app/src/lib/i18n/chunks/de-2.ts # app/src/lib/i18n/chunks/en-2.ts # app/src/lib/i18n/chunks/es-2.ts # app/src/lib/i18n/chunks/fr-2.ts # app/src/lib/i18n/chunks/hi-2.ts # app/src/lib/i18n/chunks/id-2.ts # app/src/lib/i18n/chunks/it-2.ts # app/src/lib/i18n/chunks/ko-2.ts # app/src/lib/i18n/chunks/pl-2.ts # app/src/lib/i18n/chunks/pt-2.ts # app/src/lib/i18n/chunks/ru-2.ts # app/src/lib/i18n/chunks/zh-CN-2.ts
Upstream added 23 agent-editor keys to en.ts; mirrored into all 13 locales and translated the 21 non-technical ones. Parity, English-leftover detector, typecheck and i18n tests all green.
Resolves the i18n conflict from upstream tinyhumansai#3004 (chunked chunks/<locale>-N.ts layout retired → single flat <locale>.ts files): - Accept upstream's deletion of all chunks/* files. - Re-home the conversations.subagent.* keys into en.ts (already auto-merged) and add them to every flat locale file with REAL translations (not English placeholders) — satisfies both i18n:check (parity) and i18n:english:check (no untranslated English). - CLAUDE.md i18n rule updated: locale files must carry actual translations, never English placeholders.
…olithic locale files Upstream (tinyhumansai#3004) deleted all i18n chunk files and merged them into per-locale monolithic files (ar.ts, bn.ts, …). The mic.retryingTranscription key added by this PR was in the now-deleted *-2.ts chunks; moved it to the corresponding line (after mic.transcribing) in each of the 13 locale files. en.ts already contained the key from the auto-merge.
Summary
Problem
kowas absent from the CLI coverage locale list andplwas absent from the mirror helper/test coverage list.Solution
ID,Ollama,auth-profiles.json, URL placeholders, examples, and command/model identifiers.ko/plto the relevant i18n coverage/mirror locale lists so parity checks match the app's supported locales.Submission Checklist
## Related- N/A: no feature matrix IDs affected.docs/RELEASE-MANUAL-SMOKE.md) - N/A: no release-cut smoke surface changed.Closes #NNNin the## Relatedsection - N/A: no linked issue provided.Impact
Related
AI Authored PR Metadata (required for Codex/Linear PRs)
Linear Issue
Commit & Branch
fix/i18n-locale-coverage3c8adb697284e2e12d38749f21e2e4d0469f5ec5Validation Run
pnpm --filter openhuman-app format:check(via pre-push hook)pnpm typecheckpnpm debug unit src/lib/i18n/__tests__/coverage.test.ts;pnpm exec tsx scripts/i18n-coverage.ts --json --no-unusedcargo fmt --manifest-path ../Cargo.toml --all --check(via appformat:checkpre-push hook)cargo fmt --manifest-path src-tauri/Cargo.toml --all --check;cargo check --manifest-path src-tauri/Cargo.toml(via pre-push hook)Validation Blocked
command:N/Aerror:N/Aimpact:N/ABehavior Changes
Parity Contract
scripts/i18n-coverage.ts --json --no-unusedreportsmissing=0,extra=0,drift=0for all supported non-English locales.Duplicate / Superseded PR Handling