#34630: Neither `pgettext` nor `pgettext_lazy` return contextual markers in PO
files
-------------------------------------+-------------------------------------
     Reporter:  Kamil Paduszyński    |                    Owner:  nobody
         Type:  Bug                  |                   Status:  closed
    Component:                       |                  Version:  4.2
  Internationalization               |               Resolution:
     Severity:  Normal               |  worksforme
     Keywords:  tr                   |             Triage Stage:
                                     |  Unreviewed
    Has patch:  0                    |      Needs documentation:  0
  Needs tests:  0                    |  Patch needs improvement:  0
Easy pickings:  0                    |                    UI/UX:  0
-------------------------------------+-------------------------------------

Comment (by Kamil Paduszyński):

 Replying to [comment:1 Mariusz Felisiak]:

 Thanks for rapid review and answer!

 To my surprise, it started to work on my setup (using the same version of
 `gettext`, 0.21).

 But... When I was posting the ticket, `pgettext_lazy` was aliased it with
 `_` (like this is commonly done with `gettext_lazy`). If I do not use the
 alias, everything works normally... So, it looks like the way
 `pgettext_lazy` works depends on the way it's imported. Is that even
 possible?



 > Thanks for the report, however it works for me, see e.g.
 
[https://github.com/django/django/blob/1136aa5005f0ae70fea12796b7e37d6f027b9263/django/utils/dates.py#L52-L65
 MONTHS_AP] and their
 
[https://github.com/django/django/blob/1136aa5005f0ae70fea12796b7e37d6f027b9263/django/conf/locale/en/LC_MESSAGES/django.po#L1248-L1306
 translations]. Maybe it's an issue in `gettext`, I checked with `gettext`
 version 0.21.

-- 
Ticket URL: <https://code.djangoproject.com/ticket/34630#comment:2>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/0107018887e7a7a0-37fe1c91-aab7-49e2-8307-54d251118147-000000%40eu-central-1.amazonses.com.

Reply via email to