Differences between revisions 14 and 15
Revision 14 as of 2008-02-12 17:28:28
Size: 3797
Editor: 194
Revision 15 as of 2008-03-08 16:56:58
Size: 3798
Editor: dslb-084-056-013-026
Comment: Link fix
Deletions are marked like this. Additions are marked like this.
Line 38: Line 38:
 * [http://codespeak.net/lxml lxml] has excellent support for XSLT that is based on libxslt  * [http://codespeak.net/lxml/ lxml] has excellent support for XSLT that is based on libxslt

Python and XML

A variety of XML processing solutions are available for Python. This page attempts, at the very least, to list the most actively developed or most easily available.

The standard library has a number of tools available, which fall into mainly three categories:

  • XML tree libraries that adhere to the W3C DOM standard:
    • MiniDom - the xml.dom.minidom package

    • PullDom - the xml.dom.pulldom package

  • an event-driven XML parser compatible with the W3C SAX standard:
    • ["Sax"] - the xml.sax package
  • a pythonesque XML tree library:
    • ElementTree - the xml.etree package (new in Python 2.5)

The DOM and SAX packages have the advantage of being compatible to W3C standard APIs, so users who are already familiar with these APIs can use them without learning too many new things. Everyone else should start with the more pythonic ElementTree library, which is very well integrated into the Python language, and therefore very easy to learn and use.

External packages

A long list of special purpose and general purpose Python XML packages is available from [http://pypi.python.org/pypi?:action=browse&show=all&c=500 PyPI]. The following is a choice of major tools that support a broader set of XML features.

Pythonic tools

W3C DOM-like libraries

XSLT Support

XML-based Communications

Web Services

Books and Articles

  • XmlBooks

  • ["Tutorials on XML processing with Python"]


Editorial Notes

The above lists should be arranged in ascending alphabetical order - please respect this when adding new entries. When specifying release dates please use the format YYYY-MM-DD.

PythonXml (last edited 2012-01-11 01:11:25 by c-66-41-60-82)

Unable to edit the page? See the FrontPage for instructions.