[docs] [issue18911] minidom does not encode correctly when calling Document.writexml
report at bugs.python.org
Fri May 31 06:58:06 EDT 2019
Stefan Behnel <stefan_ml at behnel.de> added the comment:
Asking users unconditionally to use the "xmlcharrefreplace" replacement method seems wrong for UTF-8. It should not be necessary.
We should, however, document explicitly that the file will receive text and not bytes, i.e. that users are themselves responsible for opening the output file with the desired encoding. We should also make it clearer that the "encoding" argument to writexml() does not change that.
Python tracker <report at bugs.python.org>
More information about the docs