xml-python
A library for making Python objects from XML.
What it is and what it does
xml-python is a library for deserializing XML documents into Python objects. Instead of working with DOM trees or ElementTree structures, you define Python classes and the library maps XML elements to object instances, letting you access XML data through normal Python attributes.
The package depends only on attrs, a lightweight library for class definition. It was last released on 2021-01-07 and has received no updates since; the project is no longer maintained. Before adopting it, verify that it works with your Python version and that its XML handling meets your use case, since there will be no ongoing support for bugs or compatibility issues.
Use it for:
- Deserialize XML configuration files into Python dataclass-like objects for easier programmatic access
- Convert XML API responses into typed Python objects instead of navigating nested dictionaries
- Map XML document structures to Python classes for data validation and type safety
- Build Python object models from XML schemas without hand-coding parser logic
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
Converts XML documents into Python objects, allowing you to work with XML data as native Python instances rather than parsing raw XML text.
No. The package is abandoned (last release 2021-01-07, no updates since) and offers no clear advantage over maintained alternatives. The lack of active maintenance means no bug fixes, security updates, or Python version compatibility improvements. Use only if you have a specific legacy dependency on this exact library.
Install
xml-python on PyPI
pip
pip install xml-pythonuv
uv add xml-pythonpoetry
poetry add xml-pythonInstalling xml-python
Before you install
Installation is straightforward with no compiled dependencies, but the package has been abandoned since January 2021. No active maintenance or bug fixes should be expected.
License in practice
Licensed under MPL (Mozilla Public License), a copyleft license. You may use and modify the code, but derivative works must be distributed under the same license terms.
Quickstart
pip install xml-python
from xml_python import XmlObject
xml_data = '<root><item>value</item></root>'
obj = XmlObject.from_xml(xml_data)
Verify before relying
- Whether the package actually supports the advertised XML-to-object conversion workflow (no working examples in fact sheet)
- Current compatibility with modern Python versions (requires_python field is empty)
- Whether attrs dependency is used for class generation or just as a utility
- How this compares to maintained alternatives for XML-to-object mapping
Package facts
| License | MPL (copyleft) |
| Python support | not specified |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | 1 — attrs |
| Maintenance | abandoned — 2,045 days since the last release |
| First released | |
| Downloads | 3,751,707/month — #2,504 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: xml_python-0.4.3-py3-none-any.whl
Tags
More Markup packages
PyYAML parses and emits YAML 1.1 data format,…
permissive · top 100 on PyPI
markdown-it-pyA Python markdown parser that converts markdown…
permissive · top 100 on PyPI
beautifulsoup4Beautiful Soup parses HTML and XML documents…
permissive · top 100 on PyPI
et-xmlfileet_xmlfile writes large XML files with minimal…
permissive · top 1,000 on PyPI
tomlkitParses and edits TOML files while preserving…
permissive · top 1,000 on PyPI
docstring-parserParses Python docstrings in ReST, Google,…
permissive · top 1,000 on PyPI
jxmleaseConverts XML to Python data structures (lists,…
permissive · top 15,000 on PyPI
py-serializableSerializes and deserializes Python classes to…
permissive · top 1,000 on PyPI
xsdataxsdata generates Python dataclasses from XML…
permissive · top 5,000 on PyPI
untangleConverts XML documents into Python objects with…
permissive · top 15,000 on PyPI
dicttoxml2Converts Python dictionaries and native data…
copyleft · top 15,000 on PyPI
pydantic-xmlPydantic-xml adds XML serialization and…
permissive · top 5,000 on PyPI
PyXB-XPyXB-X generates Python classes from XMLSchema…
permissive · top 15,000 on PyPI
xsdata-pydanticGenerates pydantic models from XML and JSON…
permissive · top 15,000 on PyPI
pyangbindPyangBind converts YANG data models into Python…
permissive · top 15,000 on PyPI
serpentSerpent serializes Python objects to…
permissive · top 15,000 on PyPI