[issue13612] xml.etree.ElementTree says unknown encoding of a regular encoding

Eli Bendersky report at bugs.python.org
Thu May 23 14:48:20 CEST 2013


Eli Bendersky added the comment:

How about this patch (not tested it too much - just as a proof of concept).

We're pretty free in the C API exported by pyexpat through a capsule to _elementtree, so we can also add a default handler there. This API already has some general utilities like ErrorString.

ET can then simply call the handler from pyexpat.

----------
Added file: http://bugs.python.org/file30347/expat_et_share_unknown_handler.1.patch

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue13612>
_______________________________________


More information about the Python-bugs-list mailing list