[Python-Dev] Is pygettext.py deprecated?

A.M. Kuchling amk at amk.ca
Mon Nov 11 22:30:38 CET 2013


I was looking at http://bugs.python.org/issue1098749, which adds
extraction of multiple-line strings to pygettext.py, but on the ticket
Mark Lawrence suggested that "pygettext should be deprecated".  Is it
deprecated?  (It's not listed in PEP 4, but it isn't a module.)

Debian wrote a man page for pygettext that starts with:

       pygettext is deprecated. The current version of xgettext
       supports many languages, including Python.

GNU xgettext didn't understand any languages other than C at one time,
so pygettext.py was written to handle Python code but not C code.  But
now xgettext will parse Python code.  I assume xgettext's
parsing is just using regexes, not an actual parse tree, so it may
work equally well for Python 2.x and 3.x.

Do we want to deprecate pygettext.py?  If so, we should rewrite
http://docs.python.org/3/library/gettext.html, which encourages people
to use pygettext, and add it to PEP4.

--amk


More information about the Python-Dev mailing list