[issue14465] xml.etree.ElementTree: add feature to prettify XML output
Raymond Hettinger
report at bugs.python.org
Sat Aug 25 16:00:03 EDT 2018
Raymond Hettinger <raymond.hettinger at gmail.com> added the comment:
A few more thoughts for consideration:
* We already have a toprettyxml() tool in the minidom package.
* Since whitespace is significant in XML, prettifying changes the content and meaning, so it doesn't round-trip and should only be used for debugging purposes.
* Usually, I recommend using XML viewers such as the one built into the Chrome browser. That provides indentation without changing meaning. It also lets you run searches and conveniently supports folding and unfolding elements. I would rather someone use a viewer rather than something like toprettyxml().
----------
nosy: +rhettinger
_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue14465>
_______________________________________
More information about the Python-bugs-list
mailing list