[New-bugs-announce] [issue34306] minidom: wrong processing of xmlns attributes

Victor Porton report at bugs.python.org
Wed Aug 1 09:32:29 EDT 2018


New submission from Victor Porton <porton at narod.ru>:

The below script prints

http://www.w3.org/2000/xmlns/
aa:aa

It should print

None
aa:aa

because xmlns:z is NOT an attribute of xmlns namespace.

~~~
import xml.dom.minidom

x = xml.dom.minidom.parseString("<x xmlns:z='aa:aa' z:q='1'/>")

for i in x.documentElement.attributes.values():
    print(i.namespaceURI)
~~~

----------
components: XML
messages: 322860
nosy: porton
priority: normal
severity: normal
status: open
title: minidom: wrong processing of xmlns attributes
versions: Python 2.7, Python 3.6, Python 3.7

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue34306>
_______________________________________


More information about the New-bugs-announce mailing list