# HG changeset patch # User cmlenz # Date 1187782682 0 # Node ID 23e60ca937cadac40aa59dad558f4ffe220a923a # Parent 2c68c69c83dc5402795b6b9d768d77a1198bd68d Merged [295:296] via svnmerge from [source:trunk]. diff --git a/babel/messages/frontend.py b/babel/messages/frontend.py --- a/babel/messages/frontend.py +++ b/babel/messages/frontend.py @@ -631,7 +631,8 @@ format = u'%%-%ds %%s' % (longest + 1) for identifier in localedata.list(): locale = Locale.parse(identifier) - print format % (identifier, locale.english_name) + output = format % (identifier, locale.english_name) + print output.encode(sys.stdout.encoding or 'ascii', 'replace') return 0 if not args: diff --git a/doc/messages.txt b/doc/messages.txt --- a/doc/messages.txt +++ b/doc/messages.txt @@ -175,8 +175,8 @@ The ``python`` extractor is by default mapped to the glob pattern ``**.py``, meaning it'll be applied to all files with the ``.py`` extension in any directory. If you specify your own mapping configuration, this default mapping -is not discarded, so you need to explicitly add it to your mapping (as shown in -the example above.) +is discarded, so you need to explicitly add it to your mapping (as shown in the +example above.) .. _`referencing extraction methods`: