Toshio Kuratomi <a.bad...@gmail.com> added the comment: I tested a small C program and found that setlocale takes precedence for LC_ALL, LC_MESSAGES, and LANG but not for LANGUAGE.
int main(int argc, char **argv) { char *message1; //setlocale (LC_ALL, ""); setlocale (LC_ALL, "pt_BR.utf-8"); bindtextdomain ("testc", "/srv/python/cpython/tmp"); textdomain ("testc"); message1 = gettext("lemon"); printf("%s\n", message1); return 0; } $ LC_ALL=es_MX.utf-8 LANGUAGE= LC_MESSAGES=es_MX.utf-8 LANG=es_MX.utf-8 ./test limão $ LANGUAGE=es_MX LANG=es_MX.utf-8 ./test limón So this could be considered a bug in the stdlib's gettext. If we fix it, we'll need to make sure that we continue to honor LANGUAGE, though. ---------- nosy: +a.badger _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue20044> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com