[Python-Dev] Small issues in gettext support (original) (raw)

Gustavo Niemeyer niemeyer at conectiva.com
Wed Apr 28 14:20:36 EDT 2004


>You belive that returning a string in some unpredictable >encoding used by the translator is explicit?

No. What is explicit here is that we return the bytes in the .mo file; and conversion of these bytes should be requested explicitly. As for compatibility with GNU gettext: Older versions of GNU gettext did not perform any conversion, either. I think changing the behaviour of an existing function was a bad thing to do for GNU gettext, as well, and I don't think we should repeat that mistake.

I wasn't aware about this.

It would be good to find out what users of Python gettext think about a possible change.

I'd be glad to hear from them as well. Anyone?

Temporarily warning about this change of behaviour is also unacceptable. Adding another function, e.g. lgettext (for local charset), along with lngettext, ldgettext, might be another solution.

Ack. Thanks for discussing.

-- Gustavo Niemeyer http://niemeyer.net



More information about the Python-Dev mailing list