Skip to content
Converting XML should be easy -- and fast.
Python
Failed to load latest commit information.
relaxml I hate the default tuple behavior May 23, 2013
README.md Update tagline Mar 11, 2012
setup.py Update version via @alekzvik pull request Jun 13, 2012
test.py I hate the default tuple behavior May 23, 2013

README.md

relaxml

Converting XML to a dictionary should be easy -- and fast.

Most of the current XML to dict projects are either unmaintained, slow, or not well-tested. This shouldn't be the case.

Installation

You can either clone this repo or use pip.

pip install relaxml

Usage

>>> from relaxml import xml

>>> some_xml = open('file.xml')
>>> xml(some_xml)
{'ohai': {'xml': 'data'}}

>>> import requests as req
>>> content = req.get('http://lots.ofxml.org').text
>>> xml(content)
{'ohai': {'xml': 'data'}}
Something went wrong with that request. Please try again.