[Python-ideas] Add "htmlcharrefreplace" error handler

Paul Moore p.f.moore at gmail.com
Fri Jun 14 12:43:08 CEST 2013


On 14 June 2013 11:11, M.-A. Lemburg <mal at egenix.com> wrote:

> I'm not sure I follow. I've definitely had use cases for the
> proposed error handler in the past and have written my own
> set of tools to do such conversions.
>

Just as an extra data point, I have also had need for this functionality in
the past. It is sometimes possible to use xmlcharrefreplace as an
alternative, but having the "named" entities in the output is often useful
for debugging, if nothing else.

The technicalities of HTML/HTTP encodings are not so much the issue here.
Much of the output of programs that would use this functionality, while
ultimately intended for consumption on the web, is often read in a text
editor as part of debugging and review, if nothing else. For that purpose,
readable output is very useful. And sticking to ASCII, while not essential,
certainly helps in an environment like Windows where UTF-8 is *not*
universal (whether it should be is really not the point here).

Paul
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-ideas/attachments/20130614/b0a1ca02/attachment.html>


More information about the Python-ideas mailing list