Issue 18319: gettext() cannot find translations with plural forms (original) (raw)

Issue18319

Created on 2013-06-27 22:53 by jwilk, last changed 2022-04-11 14:57 by admin.

Files
File name Uploaded Description Edit
test.mo jwilk,2013-06-27 22:53
Pull Requests
URL Status Linked Edit
PR 19869 open python-dev,2020-05-02 22:04
Messages (3)
msg191967 - (view) Author: Jakub Wilk (jwilk) Date: 2013-06-27 22:53
gettext() cannot find translations for messages that have plural forms. I would expect that gettext(s) is equivalent to ngettext(s, s, 1) for such messages, as it is implemented in GNU gettext. >>> import gettext >>> with open('test.mo', 'rb') as mo: trans = gettext.GNUTranslations(mo) ... >>> trans.ngettext("egg", "eggs", 1) 'Ei' >>> trans.gettext("egg") 'egg'
msg228601 - (view) Author: Mark Lawrence (BreamoreBoy) * Date: 2014-10-05 17:53
@Martin can you comment on this please.
msg368346 - (view) Author: Gilles Bassière (Gilles Bassière) * Date: 2020-05-07 14:46
Hi there, I worked on a patch for this issue (see attached pull request). I would be happy to discuss it with people involved in gettext module maintenance but I'm not sure how to contact them. Is there a dedicated mailing list or an IRC channel or something? I've found i18n-sig but it has been inactive for 5 years... Best regards Gilles
History
Date User Action Args
2022-04-11 14:57:47 admin set github: 62519
2020-09-18 20:39:10 cito set nosy: + cito
2020-06-09 22:52:39 remi.lapeyre set nosy: + barryversions: + Python 3.8, Python 3.9, Python 3.10, - Python 2.7, Python 3.4, Python 3.5
2020-05-07 14:46:56 Gilles Bassière set messages: +
2020-05-02 22:04:02 python-dev set keywords: + patchnosy: + python-devpull_requests: + <pull%5Frequest19182>stage: patch review
2020-05-01 19:36:12 Gilles Bassière set nosy: + Gilles Bassièreversions: + Python 3.7
2019-04-26 17:51:12 BreamoreBoy set nosy: - BreamoreBoy
2014-10-05 17:53:00 BreamoreBoy set versions: + Python 2.7, Python 3.4, Python 3.5nosy: + loewis, BreamoreBoymessages: + type: behavior
2013-06-27 22:53:23 jwilk create