Language variants should know their parent language
Bug #125545 reported by
Curtis Hovey
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Launchpad itself |
Triaged
|
Low
|
Unassigned |
Bug Description
Languages do not know if they are a parent or a variant language. we often use
is_english variant() which does
language.
to check if the language is a variant. This is not efficient when we want to query the db for Engligh or English variant. The Language table and object should have an parent_language column/attribute that can be queried to get the list of Persons who speak a language (because variants count as parent languages). Ah but not that is not true of pt and pt_BR, so testing the Language.code will not work. Fix model, so our code can get this right.
Changed in launchpad: | |
importance: | Undecided → Medium |
status: | New → Confirmed |
tags: | added: tech-debt |
Changed in launchpad: | |
importance: | Medium → Low |
To post a comment you must log in.
@sinzui Can you explain this a little more? As I read the description we want to do something efficiently and we can't, but the thing we do today isn't correct anyway...