You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[i18n] systemic gaps: help metadata never translated, ~600 unwrapped message sites, 36 dead keys #1050
format_help_text in src/core/cmd_meta.cppm only translates generic
section labels — command.<name>.description/.synopsis/.option.* catalog
keys exist but are never looked up at render. ~800+ help strings stay
English under zh-CN.
~600–800 emission sites bypass i18n: message fragments across multiple
print calls, ~228 std::unexpected("literal") strings invisible to the
extractor, ~30 wide L"..." diagnostics (dead legacy keys), direct std::format/safePrint literals.
36 translate()/format() keys in source are absent from the generated
catalog (wpm×17, dd×2, ln, ls×3, runcon×2, chcon×6, who/tic/toe,
mkfifo/mknod) so zh-CN can never cover them.
Remediation plan in the report: wrap all literals, teach the extractor the
call sites, translate metadata at render, translate-then-widen for wide
output, and regenerate the catalog.
Addressed in release/v1.0.6 — the concrete gaps in this report are now closed:
Help metadata: format_help_text already translates command.<name>.description, .synopsis, and every command.<name>.option.* key at render time (plus common.* section labels).
Unkeyed emission sites: all safePrint/safeErrorPrint string literals and std::unexpected("...") payloads are cataloged under legacy.<fnv64> keys and looked up at runtime via translate_legacy / translate_error.
Wide-string diagnostics: safePrint/safeErrorPrint(std::wstring_view) now narrow to UTF-8, consult the catalog, and emit the translation — the ~30 L"..." diagnostic sites are no longer dead.
Keyed call sites: scripts/i18n_batch.py extract now scans i18n::translate("key","fallback") and i18n::format("key","fallback",...) calls (literal args only), so keys no longer depend on the hand-maintained MANUAL_MESSAGES table. The regenerated catalog gained 64 previously-invisible keys (dd/numfmt/chcon/mktemp/runcon/tic/toe/who/wpm/expr/factor/tr/readlink/realpath/sleep error+warning strings).
zh-CN catalog synchronized: +64 new, -4 stale, placeholder validation clean; VERSION bumped in unixwin/winuxcmd-i18n.
Remaining raw literals (file contents, dynamic fragments) are intentionally not extracted per the documented boundary in i18n_batch.py.
Activity
caomengxuan666 commentedon Sep 15, 2026
Addressed in release/v1.0.6 — the concrete gaps in this report are now closed:
format_help_textalready translatescommand.<name>.description,.synopsis, and everycommand.<name>.option.*key at render time (plus common.* section labels).safePrint/safeErrorPrintstring literals andstd::unexpected("...")payloads are cataloged underlegacy.<fnv64>keys and looked up at runtime viatranslate_legacy/translate_error.safePrint/safeErrorPrint(std::wstring_view)now narrow to UTF-8, consult the catalog, and emit the translation — the ~30L"..."diagnostic sites are no longer dead.scripts/i18n_batch.py extractnow scansi18n::translate("key","fallback")andi18n::format("key","fallback",...)calls (literal args only), so keys no longer depend on the hand-maintained MANUAL_MESSAGES table. The regenerated catalog gained 64 previously-invisible keys (dd/numfmt/chcon/mktemp/runcon/tic/toe/who/wpm/expr/factor/tr/readlink/realpath/sleep error+warning strings).Remaining raw literals (file contents, dynamic fragments) are intentionally not extracted per the documented boundary in i18n_batch.py.
fix(i18n): translate wide diagnostics and extract keyed call sites (#…