Skip to content

console: language choice is held in memory only — any reload reverts to en, so no locale is usable beyond a demo #5406

Description

@yinlianghui

Switching the console language (avatar menu → Preferences → Language) takes
effect immediately but is never persisted. A page reload — or opening the app in
a new tab — silently returns the whole UI to en.

Reproduction (17.0.0-rc.2)

  1. Log in, switch language to 中文. UI localizes correctly.
  2. Reload (F5) or page.goto anywhere.
  3. UI is back in English; the network shows the console requesting
    GET /api/v1/i18n/translations/en again.

Analysis

Nothing is written on switch: no localStorage entry, no
sys_user_preference row, no persisting request. The locale endpoints
themselves are correct — GET /api/v1/i18n/locales lists the app's locales and
short-code resolution works (/translations/zh → the zh-CN bundle). The
selection is simply never stored anywhere, so it cannot survive a reload.

Impact

Every non-en locale is demo-only: a user cannot be a Japanese or Chinese
user of the product, only preview the translation until the next navigation.
This blocks localized trials outright — an app-side bundle can be 100% complete
(HotCRM's four locales lint at zero) and it makes no difference after the first
F5. It also complicates automated locale testing: any mid-run goto silently
reverts the UI and manufactures false "untranslated" findings.

An app cannot work around this from metadata; persistence of a user preference
is console/platform behaviour.

Downstream: objectstack-ai/hotcrm#681.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions