[XML-SIG] Empty string namespace - to bug or not to bug?
Alexis Marrero
amarre at mac.com
Wed Oct 8 20:56:07 EDT 2003
Is this a bug? Is there any work around?
doc = minidom.parseString('<root xmlns="">value</root>')
doc.toxml()
Traceback (most recent call last):
File "<stdin>", line 1, in ?
File
"/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-
packages/_xmlplus/dom/minidom.py", line 47, in toxml
return self.toprettyxml("", "", encoding)
File
"/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-
packages/_xmlplus/dom/minidom.py", line 59, in toprettyxml
self.writexml(writer, "", indent, newl, encoding)
File
"/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-
packages/_xmlplus/dom/minidom.py", line 1739, in writexml
node.writexml(writer, indent, addindent, newl)
File
"/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-
packages/_xmlplus/dom/minidom.py", line 816, in writexml
_write_data(writer, attrs[a_name].value)
File
"/Library/Frameworks/Python.framework/Versions/2.3/lib/python2.3/site-
packages/_xmlplus/dom/minidom.py", line 304, in _write_data
data = data.replace("&", "&").replace("<", "<")
AttributeError: 'NoneType' object has no attribute 'replace'
My environment is:
Python 2.3 (#2, Jul 30 2003, 11:45:28)
[GCC 3.1 20020420 (prerelease)] on darwin
Regards,
amn
More information about the XML-SIG
mailing list