Opened 6 years ago

Closed 6 years ago

Last modified 5 years ago

#12940 closed (fixed)

Comments admin should use ungettext instead of ugettext

Reported by: void Owned by: nobody
Component: contrib.comments Version: master
Severity: Keywords: i18n, comments
Cc: kmike Triage Stage: Ready for checkin
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:


Currently django.contrib.comments.admin use ugettext for actions' descriptions:

    self._bulk_flag(request, queryset, perform_approve, _('approved'))

That is because of there is no difference in English between word "approved" in phrases "1 comment was approved" and "5 comments were approved". But it's not a common for all languages. For example, verb "to approve" in passive voice in Russian would produce different forms for single and plural forms. Therefore, django.contrib.comments.admin should use ungettext instead of ugettext.

Attachments (1)

12940.txt (2.2 KB) - added by void 6 years ago.

Download all attachments as: .zip

Change History (7)

comment:1 Changed 6 years ago by russellm

  • Needs documentation unset
  • Needs tests unset
  • Patch needs improvement unset
  • Triage Stage changed from Unreviewed to Accepted

Changed 6 years ago by void

comment:2 Changed 6 years ago by dc

  • Has patch set
  • milestone set to 1.2

Please fix this before strings freeze.

comment:3 Changed 6 years ago by kmike

  • Cc kmike added

comment:4 Changed 6 years ago by jacob

  • Triage Stage changed from Accepted to Ready for checkin

comment:5 Changed 6 years ago by russellm

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

(In [12770]) Fixed #12940 -- Modified some admin actions in contrib.comments to use ungettext in order to support Russian (and similar) pluralization rules. Thanks to void for the report and patch.

comment:6 Changed 5 years ago by jacob

  • milestone 1.2 deleted

Milestone 1.2 deleted

Note: See TracTickets for help on using tickets.
Back to Top