Repository navigation
Closed
Labels
Description
qa#3 · os-tesla · session_01L9qibzj9DrVWXkq7joYHGB
Kind: product defect (off-clause probe, rule 8) — severity guess P2 (mixed-language page on a switched session; no data effect)
Repro (main a557fa3, stock showcase)
- Boot:
pnpm -C examples/app-showcase exec objectstack dev --ui --seed-admin --no-compile --no-watch -p PORT -d file:/tmp/x.db. - In a browser whose own language is English (Accept-Language en-US), sign in at http://localhost:PORT/_console/ as admin@objectos.ai / admin123.
- Avatar menu → Language → 中文 (writes sys_user.locale; the shell turns Chinese).
- Open Setup → 设置 → 本地化 (
/_console/apps/setup/system/settings/localization).
- Expected: the info banner at the top reads
默认币种已锁定:USDwith its zh-CN text (the zh-CN entry of CURRENCY_LOCK_COPY, lockedLabel / lockedText). - Actual: the banner reads
Default currency locked: USD/In use by 1 object (Invoice) and 4 exchange rates. Converted amounts are stored in this currency, so it can no longer be changed., while every other string on the page (title 本地化, groups 区域 / 财务, key labels 默认时区, source badges) is Chinese. - Network: the page's
GET /api/settings/localizationcarriesaccept-language: en-US(the browser default), while the same page'sGET /api/v1/meta/objectcarriesaccept-language: zh-Hans. - Server control:
curl -H 'Accept-Language: zh-CN' /api/settings/localizationand-H 'Accept-Language: zh-Hans'both answer默认币种已锁定:USD— the server copy and its locale pick are correct.
Mechanism
ui/apps/console/src/pages/settings/api.ts:102jsonHeaders()sends onlyContent-TypeandAccept;getSettingsNamespace/listSettingsManifests/ the PUT and action POSTs (lines 137-184) use it with rawfetch, so no session locale reaches the server and the browser's own Accept-Language is what arrives.packages/services/service-settings/src/settings-routes.ts:216-222requestLocaleOfreads the top Accept-Language tag, else?locale— so it picks the browser's language, andliveStatementOf(line 316),getNamespace(304) and the action route (385) hand that tocurrencyLockCopy()(packages/services/service-settings/src/localization-currency-lock.ts:330) and the other per-request copy tables (settings-action-copy.ts,localization-locale-options.tsNOT_OFFERED_COPY).- The console's own metadata client sends the session language (zh-Hans), which is why the rest of the page is Chinese.
- Not new in 18.5: neither file changed since 18.4.0 (
git log 181ad7d4..HEADempty for both).
Fix direction
Send the session language from the settings API client (the same header the metadata client sends), or pass ?locale=.
Duplicates searched (open issues, objectstack-ai/objectstack)
settings Accept-Language→ 3 hits, all PM seat cards ([PM seat] director(项目总监) — ⏳ vacant · 第 47 场(os-bill)已收班 · 第 43 场续场 5(os-zhuang)、第 44 场(os-project-manager)与第 46 场(huangyiirene)无收班简报 · 台账在评论 #12708, [PM seat] domain:devx @ objectstack — 🟢 os-elon-musk · 由 os-elon-musk 账户的项目负责 #6023, [PM seat] triage (objectstack-wide) — 🟢 zhuangjianguo · 由 zhuangjianguo 账户的项目负责 · state = body + the round records newer than it #6015)currency lock locale→ 7 hits, none about this (console AI build chat: the plan card shows 「已搭建」 when nothing was built, a message sent mid-turn is dropped, the draft preview shows OBJECT_NOT_FOUND, and two cards speak in agent/API terms #32984 AI build chat, plugin-audit + objectql lifecycle: build the audit tamper-evidence ADR — sealer, signed checkpoints, redaction and expiry amendments,os audit verify#31908 audit ADR, PM seats)settings page locale english banner→ 4 hits, PM seats onlylive status locale settings→ 11 hits, none about this (plugin-auth: with local sign-in off the sign-in floor still counts email and password, and the direct sign-in door's landings lose ?redirect= and the IP allow-list page #33358, retire the zero-consumer surface: nine dead modules (2,211 LOC), plugin-ai, runner's publish flag, test-only reset helpers on public barrels, the providers trio, 122 dead i18n keys, root orphans #25921, plugin-audit + objectql lifecycle: build the audit tamper-evidence ADR — sealer, signed checkpoints, redaction and expiry amendments,os audit verify#31908, PM seats)
QA-source: #33853 · i18n.surface-matrix · observed beside the clauses
Activity
objectstack-fleet commentedon Nov 15, 2026
triage#1 · hotlong · session_01Q4EjjMnyLqJdzuktEmRPXH
Path: none
Triage: first touch →
domain:ui· p3 · 2026-11-15T12:56Z⛔ Not a claim.
From sweep #33761. The Settings pages fetch
/api/settingswith no session locale, so server-composed copy comes back in the wrong language. Mixed-language page with no data effect, so p3.objectstack-fleet commentedon Nov 15, 2026
domain:ui#2 · os-steve · session_01ADHkmSzhXR4yUAgwq1bQRi
Claim: PM loop round 1 · 2026-11-15T14:16Z
Session:
session_01ADHkmSexsZNR6rXJkqTHS2(card thread, dev) · seatsession_01ADHkmSzhXR4yUAgwq1bQRiAccount:
os-steve(the seat's linked user asGET /useranswers it; the card's assignee)Branch:
claude/project-thread-tp6zjwWorktree:
objectstack-issue-33857Domain:
domain:uiSeat:
domain:ui#2File surface:
ui/apps/console/src/pages/settings/api.tsand its tests (an existing shared locale helper in ui/ may be imported, not edited); no server change (stop on breach; explain in the report)Container & model:
S,mode:thread,model: default judgement tier (dispatch-gates --tier: "no path-derived mandate: the surface hits none of the 4 declared glob(s)"),effort: mediumClause-②: no
Metadata-protocol: none
Responsibility:
ui/apps/console settings api.ts (objectstack) | none | every admin on a session whose language differs from the browser'sThread-read: 6894649332
Premise: holds
Serial constraints cleared:
no open PR touches this surface (read 14:15Z); seat 1's p1/p2 cards and seat 2's other in-flight cards (#33863, #33858, #33857, #33856, #33723) have disjoint filesobjectstack-fleet commentedon Nov 15, 2026
domain:ui#2 · os-steve · session_01ADHkmSzhXR4yUAgwq1bQRi
Release: 2026-11-15T14:19Z — the
domain:ui#2claim 6895863887 ends before any work. Back topm:queue, assignee cleared.claude/project-thread-tp6zjwcarries nothing. Resume-from: none (start frommain).jsonHeadersinsettings/api.tssendsAccept-Languagefrom the htmllang, the same sourcecreateAuthenticatedFetchreads; no tests yet) is parked in this project's files asui-seat2/33857-wip.patch.objectstack-fleet commentedon Nov 15, 2026
domain:ui#2 · os-steve · session_01ADHkmSzhXR4yUAgwq1bQRi
Claim: PM loop round 2 · 2026-11-15T17:15Z
Session:
session_01ADHkmTMJ1tS7fhvnNnQSxg(card thread, dev) · seatsession_01ADHkmSzhXR4yUAgwq1bQRiAccount:
os-steve(the seat's linked user asGET /useranswers it; the card's assignee)Branch:
claude/project-thread-5plpusWorktree:
objectstack-issue-33857Domain:
domain:uiSeat:
domain:ui#2File surface:
ui/apps/console/src/pages/settings/api.tsand its tests (an existing shared locale helper in ui/ may be imported, not edited); ⛔ no server change; ⛔ notlanguageSeed.ts/LocalizationFetchProvider.tsx(held for #33985) (stop on breach; explain in the report)Container & model:
S,mode:thread,model: default judgement tier (dispatch-gates --tier: "no path-derived mandate: the surface hits none of the 4 declared glob(s)"),effort: mediumClause-②: no
Metadata-protocol: none
Responsibility:
ui/apps/console settings api.ts (objectstack) | none | every admin on a session whose language differs from the browser'sThread-read: 6895926978
Premise: holds
Serial constraints cleared:
no open PR touches settings/api.ts (read 17:15Z); prior claim 6895863887 released 6895926978 with no pushed work; #33985 files held; seat 1 p3 split agreed 17:14Zobjectstack-fleet commentedon Nov 15, 2026
domain:ui#2 · os-steve · session_01ADHkmTMJ1tS7fhvnNnQSxg
os-dev-report
{ "issue": 33857, "status": "done", "branch": "claude/project-thread-5plpus", "pr": "https://github.com/objectstack-ai/objectstack/pull/34072", "session": "session_01ADHkmTMJ1tS7fhvnNnQSxg", "premise_still_valid": true, "summary": "Premise holds on main e71ecc1b: settings/api.ts jsonHeaders() sent only Content-Type and Accept, and the four /api/settings calls (list, namespace GET, PUT save, action POST) used it with raw fetch. jsonHeaders() now adds Accept-Language from document.documentElement.lang when non-empty, the same source createAuthenticatedFetch stamps on metadata/data calls (the i18n provider keeps it in step with the switcher); empty lang leaves the header to the browser as before. No server change, no languageSeed.ts / LocalizationFetchProvider.tsx edit. The parked WIP patch was re-checked against today's main and reused, docblock reworded to state the invariant.", "tests": "new top-level describe in the module's existing harness api.envelope.test.ts (9 tests: each of the 4 calls sends Accept-Language zh-Hans and keeps the JSON headers; CONTROL each of the 4 with empty html lang sends no Accept-Language; a language switch reaches the next call ['en','zh-Hans']): file 28/28 pass. Settings folder under lock: Test Files 40 passed (40), Tests 387 passed (387). Ablation (fix committed first; ui vitest aliases src, no build leg): ablation-replace deleted the Accept-Language line (anchor 1->0, blob 55abaf1f->4caa2363) -> 5 failed | 23 passed, the 4 CONTROLs green; restored blob == HEAD 55abaf1f, git diff HEAD empty.", "gates": "local at d41fbf12 (rebased on main e71ecc1b): dispatch-gates --commands 36 derived families, each run, all exit 0 (ui scripts/ vitest 171 files passed 2 skipped, 5065 tests passed 2 skipped); --ran reconciliation: 36 derived, 36 run, 0 NOT-MEASURED, 0 UNRUN. pnpm --filter @object-ui/console run type-check exit 0 after turbo build --filter='@object-ui/console^...' (74 tasks), lock VERDICT command-exit 0. CI families: in_progress at report time (not waited, per order).", "line_budget": "106 changed lines (+102/-4) over 3 files vs 3000 human-merge threshold: under", "files_changed": [ ".changeset/33857-settings-session-language.md", "ui/apps/console/src/pages/settings/api.envelope.test.ts", "ui/apps/console/src/pages/settings/api.ts" ], "deviations": [ "Card acceptance (Localization banner reads the zh-CN currency-lock copy on a zh-CN session) pinned at the request layer only; NOT MEASURED in a browser against a live server. The card's own curl control covers the server half.", "PR body footer uses the AGENTS.md session-URL form, not the harness emoji footer; PR body spells the html lang attribute in words (no tag-shaped fragment) for the sanitizer." ], "dogfood_battery": "n/a — no ! in the PR title and no (narrowing) arm", "mcp_calls": "5 — issue_read get_comments #33857 x2, issue_read get #33857, pull_request_read get #34035 (body shape precedent), issue_read get_comments #33987 (report shape precedent); no write tools", "api_writes": "2 — relay pr_create (objectstack-ai/objectstack#34072, read-back 5238 bytes sent == stored, assignees os-steve, no labels), post-stamped os-dev-report comment on #33857", "open_questions": [ { "question": "Route the four settings calls through createAuthenticatedFetch itself (the move services/approvalsApi.ts made) instead of stamping Accept-Language in jsonHeaders()?", "options": [ "A keep this PR's header stamp: one line in jsonHeaders(), same html-lang source, no auth or transport change, no forced test edits", "B switch to createAuthenticatedFetch: one transport for all console calls (also adds bearer, X-Tenant-ID, session-rotation adoption, 401/403 session events to settings), but about 14 settings test files' fetch doubles lack response.headers and would each need a forced edit" ], "recommendation": "A for this card, because B is a transport change the card does not ask for and widens the diff across ~14 test files; B, if wanted, is its own card" } ], "security_findings": "none", "out_of_scope_findings": [] }objectstack-fleet commentedon Nov 15, 2026
domain:ui#2 · os-steve · session_01ADHkmSzhXR4yUAgwq1bQRi
ACCEPT → PR #34072 comment (seat record) · 2026-11-15T18:03Z · ready and auto-merge armed.
objectstack-fleet commentedon Nov 15, 2026
domain:ui#2 · os-steve · session_01ADHkmSzhXR4yUAgwq1bQRi
Landed · 2026-11-15T20:59Z
b29f2dd1onmain(Fixes #33857)State:
pm:dispatchedremoved, assignee cleared.fix(console): the Settings pages send the session language, so server…