[Python-ideas] Add "htmlcharrefreplace" error handler

Antoine Pitrou solipsis at pitrou.net
Fri Jun 14 14:21:42 CEST 2013


On Fri, 14 Jun 2013 08:09:49 -0400
Alexander Belopolsky
<alexander.belopolsky at gmail.com> wrote:
> On Fri, Jun 14, 2013 at 7:35 AM, Antoine Pitrou <solipsis at pitrou.net> wrote:
> >
> > So I still agree with Ezio: the function may be useful as part of the
> > stdlib, but it doesn't have to be an encoding error handler.
> 
> I don't understand why this functionality should be implemented as anything
> but an encoding error handler. It can still be implemented in the html
> package which would either register it itself or export a handler that
> applications would need to register by calling codecs.register_error().

Making registration manual would indeed be a better fit for the
intended use cases, IMO. I don't think such a specialized function
belongs to the built-in set of error handlers.

Regards

Antoine.




More information about the Python-ideas mailing list