msgfmt -c on po file from launchpad gives "a format specification for argument 'num' doesn't exist in 'msgstr[0]'"
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Launchpad itself |
Triaged
|
Low
|
Unassigned |
Bug Description
Hello! I've been using the translations features of Launchpad with quite a bit of success, so thanks! However on 2 of my 20 or so recently exported po files, msgfmt -c complains about errors:
michael@
po/sl.po:153: a format specification for argument 'num' doesn't exist in 'msgstr[0]'
po/sl.po:303: a format specification for argument 'num' doesn't exist in 'msgstr[0]'
msgfmt: found 2 fatal errors
I've also attached my de.po file which has translated some of those sections successfully. It seems to perhaps be something to do with Plural-Forms / nplurals options, but I'm not sure! Any help would be greatly appreciated, thanks for the awesome work.
Translations in Launchpad: https:/
Thanks for the report. I am not sure why Launchpad didn't catch a problem in the translations. With Slovenian, the problem is with this message:
#: newtransactionc trl.py: 91 newtransactionc trl.py: 186 trl.py: 196
#: newtransactionc
#, python-format
msgid "Daily"
msgid_plural "Every %(num)d days"
msgstr[0] "Dnevno"
msgstr[1] "Vsakih %(num)d dni"
msgstr[2] "Vsakih %(num)d dni"
msgstr[3] "Vsakih %(num)d dni"
msgstr[0] in Slovenian is not only for 1, but for many different values. That's why msgfmt doesn't allow it without a variable. Still, Launchpad should have caught it on input and not allowed it. I'll probably make this bug about this specific problem. Workaround for you is to clear up that message, since it's badly translated anyway. :)
With Estonian, the problem seems to be that Launchpad doesn't generate a full list of empty plural messages when some of them are not provided. I believe we have a bug for that, but can't find it right now.