Skip to content

[i18n]: missing English keys in every locale cause mixed-language UI #64540

Open

Description

@unovyatr24

Description

packages/app/src/runtime/i18n/en.ts has 27 app-owned keys that at least one non-English dictionary does not translate; 23 of them are missing from all 62 locales. Each locale dictionary is merged on top of the English one ({ ...base, ...a.dict, ...b.dict } in language.tsx:112-114), so a missing key resolves to the English string, not undefined — the visible result is a mixed-language UI.

A 简体中文 user sees, for example:

Key English shown
settings.plugins.check Check for updates
settings.plugins.checking Checking for updates
settings.plugins.update Update
project.start.reconnect Reconnect
dialog.directory.breadcrumbs Folder path

Concrete places: Settings › Extensions plugin update button, the folder picker breadcrumb, and the project Reconnect state (thanks @opencodejr for confirming these on dev and bd115fd).

Expected

Every app-owned key in the English source has a translation in every locale, or is explicitly tracked as pending.

Steps to reproduce

  1. Check out bd115fd (or current dev).
  2. Compare the keys in packages/app/src/runtime/i18n/en.ts with zh.ts.
  3. 23 keys are absent from zh.ts; the runtime falls back to English for each one.

Version note

These 23 keys are not in the released @opencode/[email protected]. They landed on Nov 16–17 via #64220, #64241, #64212 and #64511, and are in the v2.3.1 tag, which is not on npm yet.

Why report this

#50772 proposed parity tests but was closed for not identifying a concrete translation failure. This is that failure. A parity test existed at packages/app/src/i18n/parity.test.ts until it was dropped in #41930. I intend to submit a small test-only PR that fails when a new English key is missing from every locale, with the currently missing keys in a temporary allow-list that shrinks as translations land.

Plugins

none

OpenCode version

source at commit bd115fd (package version 2.3.0; keys are in the v2.3.1 tag)

Operating System

macOS (reporter); the defect is locale data and platform-independent

Terminal

not applicable

Screenshot

not applicable — reproducible from dictionary contents

Activity

  1. added
    area/web
    type/bug
    version/v2
    on Nov 17, 2026
  2. opencodejr commented on Nov 17, 2026

    @opencodejr
    Contributor

    Not observed; this looks likely from reading the code.

    Thanks for the precise report. I confirmed it on the latest dev (9cfff5f) and at bd115fd by comparing the dictionaries. packages/app/src/runtime/i18n/en.ts has 23 keys that none of the 62 locale files translate. They are the keys you list, plus project.browse.*, settings.providers.disconnect.*, settings.providers.account.remove.*, settings.helpFeedback and a few others. They are all shown in the UI, for example the plugin Check for updates button in Settings › Extensions, the folder picker's breadcrumb label and the project Reconnect state.

    One small correction: t() does not return undefined for these keys. language.tsx builds each locale on top of the English dictionary ({ ...base, ...a.dict, ...b.dict }), so the English text is what shows. The visible result is the one you describe.

    Two notes on versions:

    The script below prints the keys that every locale is missing for any git ref, for example missing-keys.sh /path/to/opencode HEAD.

    Related: #53858 and #51868 (earlier reports of zh keys falling back to English) and #50772 (an earlier parity-test proposal, closed as not planned).

    Reproduction script (missing-keys.sh)
    #!/usr/bin/env bash
    # Lists app-owned English keys (packages/app/src/runtime/i18n/en.ts) that no locale translates.
    # Usage: missing-keys.sh <repo checkout> [git ref]   (default ref: HEAD)
    set -euo pipefail
    repo=${1:-.}; ref=${2:-HEAD}; dir=packages/app/src/runtime/i18n
    keys() { git -C "$repo" show "$ref:$dir/$1" | grep -oE '^\s*"[A-Za-z0-9_.-]+"\s*:' | tr -d ' ":' | sort -u; }
    keys en.ts > /tmp/en.keys
    locales=$(git -C "$repo" ls-tree --name-only "$ref" "$dir/" | xargs -n1 basename | grep -E '^[a-z]{2,3}\.ts$' | grep -v '^en\.ts$')
    n=0; : > /tmp/missing.all
    for f in $locales; do n=$((n+1)); keys "$f" > /tmp/l.keys; comm -23 /tmp/en.keys /tmp/l.keys >> /tmp/missing.all; done
    echo "ref $(git -C "$repo" rev-parse --short "$ref"): $(wc -l < /tmp/en.keys) English keys, $n locales"
    echo "keys missing from every locale:"; sort /tmp/missing.all | uniq -c | awk -v n=$n '$1==n {print "  "$2}'
    echo "missing from zh.ts: $(keys zh.ts | comm -23 /tmp/en.keys - | wc -l)"

    Run it: bash missing-keys.sh

  3. added
    status/repro-plausible
    on Nov 17, 2026
  4. Leegenux commented on Dec 1, 2026

    @Leegenux

    Following up from #67357. On dev (095d863), the 42 App Settings keys below are present in packages/app/src/runtime/i18n/en.ts and missing from all 62 non-English App dictionaries.

    The newer Preferences gaps include navigation mode, tab position and grouping, the shared side panel, the question submit key, smooth scrolling, and keeping the service running. Timeline Settings also falls back to English for the code block wrapping control.

    42 App Settings keys
    settings.about.notices.nerdFonts
    settings.about.notices.openMono
    settings.experimental.row.questionComposer.description
    settings.experimental.row.questionComposer.title
    settings.experimental.row.tabGroups.description
    settings.experimental.row.tabGroups.title
    settings.experimental.sidebarOrganize.consolidated
    settings.general.row.keepServiceRunning.description
    settings.general.row.keepServiceRunning.title
    settings.general.row.navigation.description
    settings.general.row.navigation.list
    settings.general.row.navigation.tabs
    settings.general.row.navigation.title
    settings.general.row.questionSubmitKey.description
    settings.general.row.questionSubmitKey.title
    settings.general.row.sharedSidePanel.description
    settings.general.row.sharedSidePanel.title
    settings.general.row.smoothScrolling.description
    settings.general.row.smoothScrolling.title
    settings.general.row.tabGrouping.none
    settings.general.row.tabGrouping.project
    settings.general.row.tabGrouping.server
    settings.general.row.tabGrouping.title
    settings.general.row.tabPosition.title
    settings.helpFeedback
    settings.permissions.tool.shell.title
    settings.permissions.tool.subagent.title
    settings.plugins.check
    settings.plugins.checking
    settings.plugins.update
    settings.plugins.update.label
    settings.plugins.updating
    settings.providers.account.remove.description
    settings.providers.account.remove.finalDescription
    settings.providers.account.remove.title
    settings.providers.disconnect.consoleDescription.one
    settings.providers.disconnect.consoleDescription.other
    settings.providers.disconnect.description
    settings.providers.disconnect.title
    settings.shortcuts.addKey
    settings.timeline.row.wrapCodeBlocks.description
    settings.timeline.row.wrapCodeBlocks.title
    

    The first follow-up, #67433, covers these 42 App Settings keys in Danish, German, Faroese, Icelandic, Dutch, Norwegian, and Swedish. It includes before-and-after screenshots in German and Dutch.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    area/webplatform/macosstatus/repro-plausibletype/bugversion/v2

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions