We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 02309de commit fe4437cCopy full SHA for fe4437c
1 file changed
Lib/xml/dom/pulldom.py
@@ -21,6 +21,7 @@ class PullDOM(xml.sax.ContentHandler):
21
document = None
22
23
def __init__(self, documentFactory=None):
24
+ from xml.dom import XML_NAMESPACE
25
self.documentFactory = documentFactory
26
self.firstEvent = [None, None]
27
self.lastEvent = self.firstEvent
@@ -31,7 +32,7 @@ def __init__(self, documentFactory=None):
31
32
except AttributeError:
33
# use class' pop instead
34
pass
- self._ns_contexts = [{}] # contains uri -> prefix dicts
35
+ self._ns_contexts = [{XML_NAMESPACE:'xml'}] # contains uri -> prefix dicts
36
self._current_context = self._ns_contexts[-1]
37
self.pending_events = []
38
0 commit comments