[XML-SIG] Corrected list of packages handling XML 1.1

Walter Dörwald walter at livinglogic.de
Thu Sep 1 12:50:08 CEST 2005

Ken Beesley wrote:

> My apologies to Fredrik Lundh of Pythonware for the omission of 
> ElementType+sgmlop in my recent listing of Python-XML packages that 
> handle XML 1.1. The list (that I'm aware of) currently includes: 1. 
> pxdom by Andrew Clover (http://www.doxdesk.com/software/py/pxdom.html, 
> http://www.doxdesk.com/file/software/py/pxdom.py) 2. pyLTXML from the 
> Univ. of Edinburgh (http://www.ltg.ed.ac.uk/software/xml, 
> http://www.ltg.ed.ac.uk/software/gpl_xml.html, 
> http://www.ltg.ed.ac.uk/software/xml/xmldoc/xmldoc.html) 3. elementtree 
> library from Pythonware (http://effbot.org/zone/element.htm, 
> http://effbot.org/zone/element-index.htm) If I've forgotten anyone, 
> please help me complete the list.
 > [...]

XIST (http://www.livinglogic.de/Python/xist) handles XML 1.1 charrefs 
when a parser is used that does it. (XIST uses sgmlop by default, so it 
works by default). When serializing XML those charrefs are always 
supported. See the following snippet:

 >>> from ll.xist import parsers, presenters
 >>> from ll.xist.ns import html
 >>> e = parsers.parseString("<body>this is a backspace: &#x0008;</body>")
 >>> print e.asrepr(presenters.CodePresenter())
       'this is a backspace: \x08'
 >>> print e.asBytes()
<body>this is a backspace: &#8;</body>

    Walter Dörwald

More information about the XML-SIG mailing list