[Django] #35144: Inconsistency in apostrophe symbols of translatable strings. And broken translations

23 views
Skip to first unread message

Django

unread,
Jan 25, 2024, 7:13:13 AM1/25/24
to django-...@googlegroups.com
#35144: Inconsistency in apostrophe symbols of translatable strings. And broken
translations
------------------------------------------------+------------------------
Reporter: Mārtiņš Šulcs | Owner: nobody
Type: Uncategorized | Status: new
Component: Internationalization | Version: 5.0
Severity: Normal | Keywords:
Triage Stage: Unreviewed | Has patch: 0
Needs documentation: 0 | Needs tests: 0
Patch needs improvement: 0 | Easy pickings: 0
UI/UX: 0 |
------------------------------------------------+------------------------
The usage of apostrophe symbols in source code is inconsistent, sometimes
it's `’`(0x2019), and other times it's `'`(0x27). From what I understand,
gettext does not normalize this.
Looking at the translations of contrib.auth, there are several broken
keys. For instance:

Message source -
[Link](https://github.com/django/django/blob/main/django/contrib/auth/password_validation.py#L266)
Correct id -
[Link](https://github.com/django/django/blob/main/django/contrib/auth/locale/lv/LC_MESSAGES/django.po#L270)
Wrong id -
[Link](https://github.com/django/django/blob/main/django/contrib/auth/locale/lt/LC_MESSAGES/django.po#L277)

Grepping shows there are other places where `’` is used in translatable
strings but this is the place we encountered broken translation.

I'm not familiar with how Transifex operates and whether this should be
fixed in the translation. However, the inconsistency in the source doesn't
seem ideal.
--
Ticket URL: <https://code.djangoproject.com/ticket/35144>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

Django

unread,
Jan 25, 2024, 7:39:40 AM1/25/24
to django-...@googlegroups.com
#35144: Inconsistency in apostrophe symbols of translatable strings. And broken
translations
-------------------------------------+-------------------------------------

Reporter: Mārtiņš Šulcs | Owner: nobody
Type: Uncategorized | Status: closed
Component: | Version: 5.0
Internationalization |
Severity: Normal | Resolution: invalid

Keywords: | Triage Stage:
| Unreviewed
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by Mariusz Felisiak):

* status: new => closed
* resolution: => invalid

Comment:

> I'm not familiar with how Transifex operates and whether this should be
fixed in the translation.

Yes, this should be fixed in Transifex by translators.

> However, the inconsistency in the source doesn't seem ideal.

What kind of inconsistency are you talking about? We put efforts to
improve typography of user facing strings everywhere in the source code
(check out #30400).
--
Ticket URL: <https://code.djangoproject.com/ticket/35144#comment:1>

Django

unread,
Jan 25, 2024, 7:43:12 AM1/25/24
to django-...@googlegroups.com
#35144: Inconsistency in apostrophe symbols of translatable strings. And broken
translations
-------------------------------------+-------------------------------------
Reporter: Mārtiņš Šulcs | Owner: nobody
Type: Uncategorized | Status: closed
Component: | Version: 5.0
Internationalization |
Severity: Normal | Resolution: invalid
Keywords: | Triage Stage:
| Unreviewed
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Comment (by Mariusz Felisiak):

`lt` contains old strings with `'` because no one has translated any new
strings in it since 2017.
--
Ticket URL: <https://code.djangoproject.com/ticket/35144#comment:2>

Django

unread,
Jan 25, 2024, 7:57:42 AM1/25/24
to django-...@googlegroups.com
#35144: Inconsistency in apostrophe symbols of translatable strings. And broken
translations
-------------------------------------+-------------------------------------
Reporter: Mārtiņš Šulcs | Owner: nobody
Type: Uncategorized | Status: closed
Component: | Version: 5.0
Internationalization |
Severity: Normal | Resolution: invalid
Keywords: | Triage Stage:
| Unreviewed
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Comment (by Mārtiņš Šulcs):

Thanks. So it's supposed to be `’` everywhere. I will see how to report
this in Transifex.

Just to understand how this works and what happened. Source messages get
changed without updating the keys and that invalidates all the
translations in Transifex so they need to be resubmitted?
--
Ticket URL: <https://code.djangoproject.com/ticket/35144#comment:3>

Django

unread,
Jan 25, 2024, 8:03:19 AM1/25/24
to django-...@googlegroups.com
#35144: Inconsistency in apostrophe symbols of translatable strings. And broken
translations
-------------------------------------+-------------------------------------
Reporter: Mārtiņš Šulcs | Owner: nobody
Type: Uncategorized | Status: closed
Component: | Version: 5.0
Internationalization |
Severity: Normal | Resolution: invalid
Keywords: | Triage Stage:
| Unreviewed
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Comment (by Mariusz Felisiak):

Source messages are updated on Transifex for each version (so you will
find `’` there), however, we don't fetch translations for languages
without any new translated strings. That's why there is `'` in the source
code for many-years untouched translations.
--
Ticket URL: <https://code.djangoproject.com/ticket/35144#comment:4>

Reply all
Reply to author
Forward
0 new messages