Opened 7 years ago

Closed 7 years ago

#28709 closed Uncategorized (duplicate)

makemessages creates faulty .po file

Reported by: Davor Teskera Owned by: nobody
Component: Internationalization Version: 1.11
Severity: Normal Keywords:
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

invoking

makemessages -l en

creates a faulty .po file that contains this line

"Plural-Forms: nplurals=INTEGER; plural=EXPRESSION;\n"

invoking it for other languages that i have tested creates a valid file eg. for -l hr

"Plural-Forms: nplurals=3; plural=n%10==1 && n%100!=11 ? 0 : n%10>=2 && n"
"%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2;\n"

if you afterwards call compilemessages your app will raise exceptions

ValueError: invalid token in plural form: EXPRESSION

Change History (1)

comment:1 by Claude Paroz, 7 years ago

Resolution: duplicate
Status: newclosed

Duplicate of #28085, should be fixed in Django 2.0.

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