Skip to content

web: give /about an English channel through the page dictionary - #3487

Merged
Birfy merged 1 commit into
mainfrom
dev/3479-about-locale
Dec 1, 2026
Merged

Birfy merged 1 commit into
mainfrom
dev/3479-about-locale

Conversation

@Birfy

@Birfy Birfy commented Dec 1, 2026

Copy link
Copy Markdown
Collaborator

/about is one of the pages the management gateway never renders into English, so a reader who asks for English still gets Chinese under <html lang="zh-CN">. This slice gives the page its own channel, in the shape the contacts / guide / download slice established.

Scope, 5 files, +56/-31

  • flybot_workspace/static/about/index.html: the page body marked with data-ui-text. The page had 2 data-ui-text slots before (shell.skip, shell.settings from the shell slice); this slice adds 17 about.* keys, so the page now has 19 slots and the 17 new keys are all distinct.
  • flybot_workspace/static/shell/system-locale-pages.mjs: the 17 about.* entries as [zh, en] pairs. zh values are the shipped markup text; en values are the system-language rendering.
  • runtime/flybot-workspace-web/src/pages.js: about joins LOCALE_PAGES and PAGE_MESSAGE_PAGES.
  • tests/system_locale.test.mjs: the page-level case extended to /about.
  • docs/inventory/visible-controls.json: regenerated with the in-tree scripts/visible_inventory.py.

No new inline wrappers. The page's <span> count is 2 before and 2 after this slice, so unlike the contacts / guide / download slice there is no text-plus-control pairing here: only attributes were added, and the visible text stream is untouched. Stripping data-ui-* on both sides gives the same bytes.

Inventory. Regenerated on this tree: counts stay 1913 / 266 / 6 / 24, the line column does not move, and exactly 5 records change, all in about/index.html (:31, :32, :61, :65, :66), all only in data. Two consecutive runs give the same bytes (1ec7af6e).

Rendering, measured on this tree. 23 pages × 2 languages, with /assets/<32hex>/ normalized: 46 renders, 44 identical to the base tree, and the only differences are /about in both languages. On the en side the page renders with 0 static CJK, lang="en" and content-language: en; on the zh side content-language: zh-CN.

One behaviour change to be explicit about. /about now sends content-language where it previously sent none: the counts move from {en: 5, zh: 5} to {en: 6, zh: 6}. That is the same header behavior chat, settings and the three pages from the earlier slice already have, and it is what gating the page means.

Local, not CI, bound to tree 67b02ab7: tests/*.test.mjs 974 pass / 0 fail / rc 0; full python suite Ran 379 tests ... OK / rc 0 / 154.0 s under /usr/bin/python3.

Not claimed: no parity claim and no acceptance sign-off. The handler output is still not the file bytes (markHtml injects two metas and rewrites asset paths), so the zh comparison is served-vs-served after normalization, not "the handler returns the original text". Screenshot baselines do not move: visible labels are unchanged, only attributes were added.

Refs #3479

/about was one of the 21 pages the server never renders into English, so it
shipped Chinese under <html lang="zh-CN"> whatever language the reader asked
for. This slice marks its own body, adds the page keys to the shared page
dictionary, and lets the gate render it, following the shape the contacts,
guide and download slice established.

Related #3479
@github-actions github-actions Bot added the risk:T1 Risk tier T1 (client, tests, generated files), set by the controller from the diff label Dec 1, 2026
@Birfy

Birfy commented Dec 1, 2026

Copy link
Copy Markdown
Collaborator Author

Lead review for head 401868395a04fd5edb1e3a0ce641974a47aea606 — this record is void as soon as a new commit lands on the branch.

Identity. Head 4018683, tree 67b02ab7d4cb39c5ef8e097592ea4bb505584331, single parent ea149149 (current main, tree d6967b67), 2579 entries, no __pycache__/*.pyc. I replayed the author's patch myself on a fresh tarball of ea149149: base tree reproduced bit-for-bit as d6967b67, git apply --check rc 0, write-tree after the patch = 67b02ab7, matching both the author's and QA's numbers.

Slice, 5 files, +56/-31. static/about/index.html 5ab61e73/3,792 B; static/shell/system-locale-pages.mjs 44b303eb/6,958 B; runtime/flybot-workspace-web/src/pages.js edde3ac0/14,081 B (was 8e0241f7/14,056); tests/system_locale.test.mjs 699a1d11/5,436 B; docs/inventory/visible-controls.json 1ec7af6e/859,013 B.

Mechanism. pages.js adds about to both LOCALE_PAGES and PAGE_MESSAGE_PAGES; system-locale-pages.mjs carries the about.* pairs as [zh, en]. The page already had 2 data-ui-text slots from earlier shell work (shell.skip, shell.settings), so 17 new about.* keys bring it to 19 — the "+17", not "+19", is the correct count.

Visible text is untouched. The page's <span> count is 2 before and 2 after, so unlike the contacts/guide/download slice there is no new text-plus-control pairing here. Stripping data-ui-* on both sides gives the same bytes; the 17 zh dictionary values equal the shipped markup text exactly.

Inventory. Regenerated with the in-tree scripts/visible_inventory.py on this tree: counts stay 1913/266/6/24, the line column does not move, and exactly 5 records change, all in about/index.html (:31, :32, :61, :65, :66), all only in data. Regeneration is idempotent (1ec7af6e twice).

Rendering. 23 pages × 2 languages with /assets/<32hex>/ normalized: 44 of 46 renders identical to the base tree, the only differences being /about in both languages. On the en side 0 static CJK, lang="en", content-language: en; on the zh side content-language: zh-CN.

One behaviour change, stated on purpose. /about now sends content-language where it previously sent none: {en: 5, zh: 5} → {en: 6, zh: 6}. That is the header behaviour chat, settings and the three pages of the earlier slice already have; it is what gating the page means and it is in the PR body rather than left for a reader to discover.

Local, not CI, bound to tree 67b02ab7: tests/*.test.mjs 974 pass / 0 fail / rc 0; full python suite Ran 379 tests … OK / rc 0 / 154.0 s under /usr/bin/python3. The conda env's single error (test_isolated_bot_social, missing yaml) is a known environment gap, not this slice.

CI, bound to exactly this head 4018683: 18/18 success, non_success = [].

  • FlyBot required checks 142552109455
  • Management API · Python 3.11 142545688384 · Python 3.13 142545688113
  • Risk tier label 142545686913 (verdict risk:T1)
  • Web and compose planner 142545688476
  • browser / screenshots 142545688858
  • provenance / provenance 142545689115 · bot-social-source-tests 142545689199 · flybot-social-plugin-tests 142545688839
  • runtime-image / Build and smoke under the manager contract 142545689094 · Image recipe contract tests 142545688899
  • silent-revert 142545687271
  • social-host / Façade and ledger unit tests 142545688306 · Social plugin on the pinned DS-Bot host 142545688830
  • upstream / Pin and vendor tree 142545688485 · Container startup smoke 142545947957 · Upstream suite · Node 22 · DSH from pin 142545947859 · Node 24 142545947888

Not claimed. Not a parity claim and not an acceptance sign-off. The handler output is still not the file bytes (markHtml injects two metas and rewrites asset paths), so the zh comparison is served-vs-served after normalization, never "the handler returns the original text". Screenshot baselines do not move: visible labels are unchanged, only attributes were added.

@Birfy
Birfy added this pull request to the merge queue Dec 1, 2026
Merged via the queue into main with commit 60a5f0a Dec 1, 2026
18 checks passed
@Birfy
Birfy deleted the dev/3479-about-locale branch December 1, 2026 10:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

risk:T1 Risk tier T1 (client, tests, generated files), set by the controller from the diff

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant