New submission from Einar Fløystad Dørum:
The tostringlist documentation says "Returns a list of (optionally) encoded
strings containing the XML data. It does not guarantee any specific sequence,
except that "".join(tostringlist(element)) == tostring(element).".
But in reality it is possible to get tostringlist to return a string and not a
list.
The following code will demonstrates problem, by failing with a TypeError:
from xml.etree.ElementTree import Element, tostringlist, tostring
element = Element("foo")
print ("".join(tostringlist(element)) == tostring(element))
----------
components: XML
messages: 171434
nosy: einarfd
priority: normal
severity: normal
status: open
title: xml.etree.ElementTree.tostringlist does conform to it's documentation
type: behavior
versions: Python 3.3
_______________________________________
Python tracker <[email protected]>
<http://bugs.python.org/issue16082>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe:
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com