Repository navigation
fix(web): pick backup and restore wording for the exact number of items - #4741
Conversation
Seven backup and restore messages in the web admin chose "it" or "them" with a plural on a count they never print. In Russian, Ukrainian, Croatian, Lithuanian and Latvian CLDR's "one" form also covers 21, 31 or 101, and in Slovenian 101, so 21 omitted accounts read "its data is too large" and the Restore page offered "Show it" for 21 items. The callers now pass exactAmount(count), and the catalog selects on exactlyOne, exactlyTwo (for the Slovenian and Arabic dual) or other. English is unchanged. docs/architecture/i18n.md and the web i18n README now say when a web message selects on the exact amount instead of a plural. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Codex Review Summary: ✅ CompletedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
Warning Review limit reachedEnable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
Reviews can continue after your included limit without a manual trigger. An admin must approve usage-based billing. Next included review available in 4 minutes. View limit details
|
Silo Kody — review completeReview finished. Check the inline comments for findings and verify each suggestion against the code and tests. Reviewing changes in Silo
Review settingsReview OptionsThe following review options are enabled or disabled:
|
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 1b541863c9
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
Re-pin web translations to silo-translations 2026.11.21-b2f2d7a, which includes Silo-Server/silo-translations#135, and have the backup warning toggles use the shared exactAmount() from @/i18n. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Quick104
left a comment
There was a problem hiding this comment.
Review of 1a6ae26 (main merged in). The code change holds up. Every caller of the seven keys passes amount, all 41 web catalogs select on amount with all three cases, the pinned release only adds keys, and rendering the real ru, lv and sl catalogs shows the plural wording at 21 and 101 and the singular kept for exactly one. One docs finding is below.
🤖 Claude Code (claude-opus-5-5)
…here one is not exactly one Co-Authored-By: Claude Opus 5.5 <[email protected]>
Code Review Completed, but its comments could not be posted
|
| Options | Enabled |
|---|---|
| Bug | ✅ |
| Performance | ✅ |
| Security | ✅ |
| Business Logic | ❌ |
Maintainer review summaryReviewed head: 4492f0a (code reviewed at 1a6ae26; the last commit only changes docs) Fit: 9/10 · Readiness: 9/10 — ready (assuming CI is green)
What changed in this review
How it was checked
Council (round 2, on 1a6ae26)
The docs wording finding (Opus, plus a code-review finder) is fixed. The suggestions to add more tests are answered: the backup warning toggle tests already cover Left for the maintainers
Other checks
🤖 Claude Code (claude-opus-5-5) |
#4741 was squash-merged into main as 5641447, so this branch's copies of its commits are resolved to main's versions. The web stays pinned to silo-translations 2026.11.21-06af3eb, which builds on main's b2f2d7a; the diff against main is now only this PR's change. Co-Authored-By: Claude Opus 5.5 <[email protected]>
#4741 landed on main as 5641447, so this drops its original commits from the branch. Keep the web translations at 2026.11.21-04a2222, which adds only the three Ambiguous Roots confidence keys to main's 2026.11.21-b2f2d7a. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Problem
Related issue: N/A
Validation tasks: none
Other clients: N/A (web admin only: these messages are web-only keys on the Backups and Restore pages, which Apple, Android, and Roku don't have)
In several languages, seven Backups and Restore messages in the web admin read as if there were one item when there are 21, 31, or 101. They choose between "it" and "them" with an ICU
pluralon a count they never print. CLDR'sonecategory isn't "exactly one": in Russian, Ukrainian, Croatian, Lithuanian, and Latvian it also covers 21, 31, 101, and in Slovenian 101 and 201. This change picks the singular only for exactly one item. English is unchanged.On main, with the translations pinned there:
web.admin.backups.warnings.tooLarge,dataUnreadable,partUnreadable).web.admin.backups.restore.choose.showThem/hideThem).web.admin.backups.restore.notice.alsoChose/alsoUnchose).Approach
The seven keys now
selecton a String{amount}that the caller sets:exactlyOne,exactlyTwo, orother, from a newexactAmount(count)inweb/src/i18n. This matches the backup warning toggles (Silo-Server/silo-translations#132, #136).exactlyTwokeeps the dual that Slovenian and Arabic use for exactly two items, which the oldpluralgot right. In English it has the same text asother.The catalog change is Silo-Server/silo-translations#135, merged and published in release 2026.11.21-b2f2d7a, which this branch pins. The backup warning toggles from #4737 now use the shared
exactAmountin place of their file-local copy.docs/architecture/i18n.mdandweb/src/i18n/README.mdgain the rule: apluralis for words that agree with the number printed beside them. Words that refer to the items as one or several ("it"/"them", "its"/"their") select on the exact amount in new or changed web-only messages. The rule names older web messages and native keys, which have noselect, as still usingplural. Other web messages outside Backups have the same problem; #4743 tracks them.Validation
groupOmissionsandchooseItemsagainst the real ru, uk, hr, lt, lv, and sl catalogs at 1, 2, 5, 21, and 101 items. 18 of 25 cases failed on main and all pass with this change. The script is not committed, because CONTRIBUTING rules out tests for wording.make checkandmake check-completepass on API v2 program epic: /api/v2 contract reset on Huma, bounded bridge, v1 retirement at 1.0 #135.Evidence
Evidence: https://evidence.siloserver.org/r/silo-server/pr-4741/
Surface and build: web admin Restore page (choose step) and backup warning details. Before is main at ba62a27 with the pinned translations; after is this branch with #135's catalog. Captured at desktop and iPhone widths in Croatian, Latvian, Lithuanian, Russian, Ukrainian, and Slovenian (21 or 101 items), Slovenian and Arabic at 2, and English at 1 and 21. No test server was available, so the captures come from a temporary local route that renders the real
RestoreChoosepage with a seeded restore set. That route is not part of this change.Risks
The placeholder changes from
counttoamount. A build that pairs this code with a translations release older than 2026.11.21-b2f2d7a would render these seven messages as format errors; this pull request carries the pin to that release.Checklist
Council review
Rounds: 2, last reviewed 1a6ae26
Visual review: 1 round, captures of the code in 1b54186
Round 1 fixed: none needed. Answered: Sol's one finding,
web.admin.backups.restore.nothing.allMatch, predates this change and moved to #4743. Gemini hit its quota limit on the first run and on the retry, and posted nothing.Round 2 (maintainer review, after merging main): fixed the
docs/architecture/i18n.mdrule's wording about older web messages and its incomplete language lists, in a docs-only commit. Answered: the requests for more tests (exactAmountis already exercised through the backup warning toggle tests, and the restore notices run inrestoreModel.test.ts, where a missing value throws). Left for the maintainers: the LithuanianalsoUnchosewording, which predates this change.AI Disclosure
alsoUnchose, theexactlyTwobranch, and the catalog merge order), the captures, and the pull request; see Council review. A multi-agent code review asked for the web i18n README update and the release re-pin.🤖 Generated with Claude Code
Note
Use exact-count
amountselectors for backup and restore item wordingexactAmountutility in format.ts that maps counts toexactlyOne,exactlyTwo, orother, so messages pick wording for the exact number of items instead of CLDR plural categories.amount: exactAmount(count)instead of a numericcount.countplurals toamountselects, and new translations are added for the backup missing-file warning keys and thegoToPage/pastEndrequest-pagination messages.count-based plural values; unconverted callers passing onlycountwould miss the exact-amount branches.Macroscope summarized 4492f0a.