• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

agama-project / agama / 27955131143
83%

Build:
DEFAULT BRANCH: master
Ran 22 Jun 2026 01:13PM UTC
Jobs 3
Files 1018
Run time 2min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

22 Jun 2026 01:10PM UTC coverage: 83.095% (+0.2%) from 82.895%
27955131143

push

github

web-flow
fix(web): apply UI language and keymap changes without a page reload (#3657)

## Summary

- Changing the installer UI language (and keymap) from the localization
dialog now updates the interface right away, without needing a manual
page reload.
- The translation catalog is loaded as plain query data and applied to
the global translation singleton on every provider render, so the
visible texts always match the selected language.
- Language and keymap are now updated through a single `changeL10n`
request.
- Adds regression tests covering a language change and the catalog
staying in sync across re-renders.

## Motivation

When changing the UI language from the localization dialog (for example
English to French), the interface did not update reliably:

- It frequently kept the **previously selected** language (not
necessarily English).
- The result was **intermittent**: sometimes it worked, sometimes it did
not, depending on timing.
- A manual page reload always applied the correct language.

The product descriptions did update, because they come **already
translated from the backend** in the `system` query payload. Only the
frontend UI strings (loaded from the `po.<lang>.js` files) were
affected.

## Root cause

UI strings are translated through a global singleton (`agama`, used by
the `_()` helper), which is updated by calling `agama.locale(catalog)`.
Previously that call happened **as a side effect inside the translations
query function** (`loadTranslations`), and the query was cached per
language.

That made applying the active catalog depend on cache state and on the
order in which asynchronous queries resolved, which is fragile in two
ways:

1. **A cached language did not re-apply its catalog.** The query
function only runs when the query actually fetches. With the cached
query served as-is, `agama.locale(...)` was not called again, so the
global catalog could stay on a different language than the one being
rendered.
2. **An out-of-order load could ... (continued)

4795 of 6689 branches covered (71.68%)

Branch coverage included in aggregate %.

25 of 27 new or added lines in 2 files covered. (92.59%)

15 existing lines in 3 files now uncovered.

25135 of 29330 relevant lines covered (85.7%)

124.73 hits per line

Uncovered Changes

Lines Coverage ∆ File
2
83.72
40.13% web/src/context/installerL10n.tsx

Coverage Regressions

Lines Coverage ∆ File
8
87.23
0.0% web/web/src/test-utils.tsx
4
94.74
0.08% web/web/src/components/core/InstallerL10nOptions.tsx
3
94.44
42.93% web/web/src/context/installerL10n.tsx
Subprojects
ID Flag name Job ID Ran Files Coverage
3 web 27955131143.3 22 Jun 2026 01:13PM UTC 701
79.92
GitHub Action Run
1 rust 19474749743.1 18 Nov 2025 05:18PM UTC 185
22.45
GitHub Action Run
3 service 27558713690.3 15 Jun 2026 03:59PM UTC 317
92.39
GitHub Action Run
Source Files on build 27955131143
  • Tree
  • List 1018
  • Changed 8
  • Source Changed 3
  • Coverage Changed 8
Coverage ∆ File Lines Relevant Covered Missed Hits/Line Branch Hits Branch Misses
  • Back to Repo
  • Github Actions Build #27955131143
  • 3c39c9b8 on github
  • Prev Build on master (#27829922750)
  • Next Build on master (#27960976120)
  • Delete
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc