Code

Opened 7 years ago

Closed 7 years ago

#4841 closed (wontfix)

Same English phrase - different Swedish phrases

Reported by: philip@… Owned by: mtredinnick
Component: Translations Version: master
Severity: Keywords:
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:

Description

The same English word has two different translations, depending on context. Is this possible to fix somehow?

A specific example:

The English word "March" is used twice in the file utils/dates.py has two different translations when translated to Swedish.
On line 18 "March" is marked for translation in the context of being the full month name.
Next, on line 31 "March" is in the context of being in the Associated Press style.
For a Swedish translation, I'd like to have the AP style months abbreviated, but not the full month names.
I don't know how to solve this.

Another example:
The word "one" in contrib/humanize/templatetags/humanize.py on line 68 is translated to "en" or "ett" (Swedish) depending context.
This is probably pretty hard to solve.

Attachments (0)

Change History (2)

comment:1 Changed 7 years ago by Ludvig Ericson <ludvig.ericson@…>

  • Needs documentation unset
  • Needs tests unset
  • Patch needs improvement unset

As for numbers, the number one is 'en etta,' or 'ett' and I'd bet you know this. But yes, there's an issue when translating to languages which have neutrum and utrum.

comment:2 Changed 7 years ago by mtredinnick

  • Resolution set to wontfix
  • Status changed from new to closed

There's nothing we can really do about these. MO file lookup works by byte matching, so the same string of bytes/characters cannot be translated in two different ways.

All you can do in those cases, unfortunately, is recommend that people don't use the Associated Press versions in their non-English text output (which kind of makes sense anyway -- AP's style guide is very North American-centric).

Particularly the apnumber filter is something we can't solve. Filters can't really look ahead and change their behaviour based on the following text (which they won't even have access to, in many cases). Again, sites requiring localisation into languages with gender-specific word endings are going to have to use more specialised filters in those cases.

Add Comment

Modify Ticket

Change Properties
<Author field>
Action
as closed
as The resolution will be set. Next status will be 'closed'
The resolution will be deleted. Next status will be 'new'
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.