Message143391
I can get not-well-formed XML output (attribute name must not be empty string):
<?xml version="1.0" encoding="iso-8859-1"?>
<root ="v_for_empty_name" k1="v1"></root>
AttributeImpl must ignore dict entries that may not be cast to valid XML attributes.
Code:
#!/usr/bin/python
from xml.sax.xmlreader import AttributesImpl as Attrs
from xml.sax.saxutils import XMLGenerator as Gen
g = Gen()
a = Attrs(dict([('k1','v1'),('','v_for_empty_name')]))
g.startDocument()
g.startElement('root',a)
g.endElement('root')
g.endDocument()
print |
|
Date |
User |
Action |
Args |
2011-09-02 10:04:02 | Michael.Sulyaev | set | recipients:
+ Michael.Sulyaev |
2011-09-02 10:04:02 | Michael.Sulyaev | set | messageid: <1314957842.78.0.391568748992.issue12883@psf.upfronthosting.co.za> |
2011-09-02 10:04:02 | Michael.Sulyaev | link | issue12883 messages |
2011-09-02 10:04:01 | Michael.Sulyaev | create | |
|