[XML-SIG] Conditions for using XLink
Dinu Gherman
gherman@darwin.in-berlin.de
Thu, 04 Apr 2002 14:27:19 +0200 (CEST)
Hi,
I'm trying to read XML files with FromXmlFile() that contain XLink attri-
butes like this: <foo xlink:href="#bar"/>. This results in the following
traceback below. I'm using the following environment:
OS name: posix, platform: darwin
Python version: 2.2.0 final 0
PyXML version: 0.7
4Suite version: 0.11.1
Is there anything else needed to work with XLink or do I need to upgrade
something?
Thanks,
Dinu
[...]
File "foo.py", line 727, in foo
doc = FromXmlFile(path)
File "/usr/local/lib/python2.2/site-packages/_xmlplus/dom/ext/reader/Sax2.py", line 401, in FromXmlFile
saxHandlerClass, parser)
File "/usr/local/lib/python2.2/site-packages/_xmlplus/dom/ext/reader/Sax2.py", line 386, in FromXmlStream
return reader.fromStream(stream, ownerDocument)
File "/usr/local/lib/python2.2/site-packages/_xmlplus/dom/ext/reader/Sax2.py", line 372, in fromStream
self.parser.parse(s)
File "/usr/local/lib/python2.2/site-packages/_xmlplus/sax/expatreader.py", line 58, in parse
xmlreader.IncrementalParser.parse(self, source)
File "/usr/local/lib/python2.2/site-packages/_xmlplus/sax/xmlreader.py", line 123, in parse
self.feed(buffer)
File "/usr/local/lib/python2.2/site-packages/_xmlplus/sax/expatreader.py", line 143, in feed
self._parser.Parse(data, isFinal)
File "/usr/local/lib/python2.2/site-packages/_xmlplus/sax/expatreader.py", line 217, in start_element
self._cont_handler.startElement(name, AttributesImpl(attrs))
File "/usr/local/lib/python2.2/site-packages/_xmlplus/dom/ext/reader/Sax2.py", line 72, in startElement
attr = self._ownerDoc.createAttributeNS(namespace, qname)
File "/usr/local/lib/python2.2/site-packages/_xmlplus/dom/Document.py", line 149, in createAttributeNS
raise NamespaceErr()
xml.dom.NamespaceErr: Invalid or illegal namespace operation