Problem
The per-project translations check reports two directions, and the "missing" one is fed by potx, which was never given config/install or config/optional. A string that only a shipped configuration entity carries was therefore never required to have a translation, and 24 of them had none in the catalog of the project that ships them.
What was untranslated
- Fifteen strings in
orchestra_interaction_webform_examples: the flow labelsAwaiting validation,Requested changes,ProcessedandRejected, the three shipped status labelsBeing processed,Changes requestedandUnder review, the four sentences a requester reads about their own submission, the form titleRequest validation, and the bodies of the three Easy Email templates the module ships asconfig/optional. PaidandExpired, flow labels inorchestra_payment_example.Orchestra timestampand the patternY-m-d H:i:s, the date formatorchestra_uiinstalls.- Four view labels and descriptions in
orchestra_inbox_viewsandorchestra_views, and one message inorchestra_examples.
#3620615 fixed this for the two modules whose shipped strings it happened to touch, and each of those got a unit test asserting its own configuration was covered. Nothing generalized that to the rest of the project, which is why these 24 were still here. Those two per-module tests are removed: one mechanism now covers every module, and it is exercised against the whole tree rather than two modules having their own.
The rule for a string somebody else already translates
Feeding the shipped configuration directories to potx also reports wording that Drupal core itself ships and translates: Apply, Reset, Sort by, Asc, Desc, Items per page, - All - and the pager, all of it exposed-form and pager chrome serialized inside the views this project installs. locale keeps one string table for the whole site, so those already read in French from core's own catalog, and duplicating them per project would be wrong as well as unmaintainable.
The rule chosen is a second allow-list, translations/untranslated-in-config.txt, read only for a value a shipped configuration entity carries. It has to be separate from translations/untranslated.txt, which exempts a string everywhere: Apply is core's wording inside a shipped view and a button this project writes itself, and one list for both stopped the check asking for either. Each entry carries the reason it is there, and every one was checked against a French site's string table rather than assumed.
Other holes in the same script
- A translation context was not part of the key on either side, so a contextless entry satisfied a string locale looks up under a context. That is why the date format shipped with an entry that never applied: the site rendered the English pattern.
- The catalog reader took
msgidandmsgid_pluraland never looked atmsgstr, so an entry whose translation is empty or marked fuzzy counted as present while locale ignores it at runtime. - Seven entries in
orchestra_interaction_webform_examplescould never be looked up at all. A webform stores its whole element tree as one string and webform's schema types that key as a singletextvalue, so the translatable string locale registers is the entire document, not the'#title'values inside it. The entries are deleted, the reason is written down in the module's README, and the check now reports that class of entry. - A shipped-config string was asked for against the project's declared dependencies only, one level deep. Installing a module installs its dependencies' dependencies too, so three projects were reading a smaller set of catalogs than they may rely on, two of them missing 105 strings.
- The flag saying where an extracted string came from was combined across every file it appears in, so a string written in code and also carried by shipped configuration was checked the looser of the two ways. Each obligation is now asked of the origin that owes it.
- Which values count as translatable depends on the config schemas potx finds, so the same commit reached a different verdict on a lean checkout than on a development root holding hundreds of contrib projects. The schema set is now derived from what this project ships, and the check asserts a budget on it, because potx re-reads core's schemas once per module it has seen files from.
AI-Generated: Yes (Claude Code was used to write the code and the tests on the merge request, to draft this issue summary, and to take the measurements it reports. I reviewed the code, the measurements and the wording before posting.)
Issue fork orchestra-3620839
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #3
mably commentedComment #4
mably commentedComment #6
mably commented