Address rows: the State box reads 'Zustand' in German, because the core's 'State' (a status) answers for the plugin's #651

Closed
opened 2026-10-01 21:24:21 +00:00 by tiagoagueda · 0 comments
Owner

Found while reviewing #306; older than it, and now beside #306's "needs a state".

What happens

On Your details, the box for the state of a postal address in the United States, Australia
or Brazil reads Zustand in German and Κατάσταση in Greek: the word for a condition, a
status. The address-rules plugin's own catalogues say Bundesstaat and Πολιτεία, which
is right, and they are never reached.

Why

The plugin's label is the msgid State with no context. The core has the same msgid, for a
status, and the core's catalogue answers first. Two meanings share one msgid, so whichever
catalogue is asked first decides for both.

What should happen

The address part's label carries a context (pgettext_lazy("part of a postal address", "State")), so it is a message of its own and the plugin's translation is the one drawn.
The translations the plugin's catalogues already hold for State move to the entry with
the context, in every language that has one: they are carried, not written again.

Look for the same collision on the plugin's other labels (Province, District, County,
Region, Town, City, Postcode): any that the core also has under another meaning gets
the same treatment.

Acceptance

  • In German the box reads Bundesstaat, in Greek Πολιτεία; a test draws the row in both.
  • No translation the plugin's catalogues held is lost: a test or a count in the commit
    message says how many entries moved.
  • A test that fails if a label of the address plugin shares a msgid, without context, with
    a message of the core.
Found while reviewing #306; older than it, and now beside #306's "needs a state". ## What happens On *Your details*, the box for the state of a postal address in the United States, Australia or Brazil reads *Zustand* in German and *Κατάσταση* in Greek: the word for a condition, a status. The address-rules plugin's own catalogues say *Bundesstaat* and *Πολιτεία*, which is right, and they are never reached. ## Why The plugin's label is the msgid `State` with no context. The core has the same msgid, for a status, and the core's catalogue answers first. Two meanings share one msgid, so whichever catalogue is asked first decides for both. ## What should happen The address part's label carries a context (`pgettext_lazy("part of a postal address", "State")`), so it is a message of its own and the plugin's translation is the one drawn. The translations the plugin's catalogues already hold for `State` move to the entry with the context, in every language that has one: they are carried, not written again. Look for the same collision on the plugin's other labels (*Province*, *District*, *County*, *Region*, *Town*, *City*, *Postcode*): any that the core also has under another meaning gets the same treatment. ## Acceptance - In German the box reads *Bundesstaat*, in Greek *Πολιτεία*; a test draws the row in both. - No translation the plugin's catalogues held is lost: a test or a count in the commit message says how many entries moved. - A test that fails if a label of the address plugin shares a msgid, without context, with a message of the core.
tiagoagueda added this to the 0.5.0 milestone 2026-10-01 21:24:21 +00:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
Postulo/postulo#651
No description provided.