Translations: status.json is stale, so 36 languages at 70 % are offered as complete drafts #495
Labels
No labels
accessibility
authentication
breaking change
bug
documentation
enhancement
interface
internationalisation
observability
performance
security
tier
1
tier
2
tier
3
tier/4
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
Postulo/postulo#495
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Found on 2026-09-29 in a read-only review of postulo at
95348908d, by recomputing the translation report with the tool's own functions and comparing it with the committed file.Checked again on 2026-10-01 against
mainat0a5cad587: still present. The code is now ataccounts/forms.py:193(language_choices) andaccounts/forms.py:840(the same test for Defaults); the other locations are unchanged. The catalogues were extracted again since the review andstatus.jsonwas not rewritten, so the figures below are the ones recomputed at this commit.The language picker and the bars on Server settings → Defaults read only
locale/status.json. That file is written byscripts/messages.py stats --writeand by nothing else, and nothing checks it. The committed copy counts 1,873 strings per language. The catalogues now hold 3,119. So 36 languages that are 70 % translated are shown as complete, and the reviewed share of French and European Portuguese is shown as nothing.Where:
locale/status.json;core/messages_tool.py:818(cmd_stats, the only writer);core/languages.py:356(translation_status, the reader);accounts/forms.py:192(language_choices, the< 95test that marks a language partial) andaccounts/forms.py:843(the same test for Defaults);.forgejo/workflows/ci.yml:100-105, which runsextract --checkandcheckbut nothing that comparesstatus.jsonwith the catalogues;docs/TRANSLATING.md:159, which leaves it to contributors to runstats --writeby hand.What happens:
stats_for(_as_the_reader_sees_it(...))over the snapshot's catalogues givestotal: 3119for every language.status.jsongivestotal: 1873for all 68, and differs for all 68. Two consequences:fr-frandpt-ptare stored withreviewed: 0, though 153 of their strings are reviewed, so their bars show no reviewed part.Why it matters: somebody who picks German or Polish is told the interface is complete and gets one where nearly a third of the strings are English. The figure shown is the one #312 and #127 exist to make true.
Fix: make the file impossible to forget.
stats --check, which fails when a fresh report differs from the stored one, and run it inci.ymlbesideextract --check.extract(orcompile, which CI, the release workflow and the image build all run) writestatus.jsonitself.Computing the report from the catalogues at start-up is the alternative, but the image deletes the
.pofiles (docker/Dockerfile:101-104), so it would have to read the compiled.mofiles instead.Done when
tests/test_messages_tool.pyasserts that the committedlocale/status.jsonequals whatcmd_statswould write for the current catalogues. It fails today for all 68 languages.