Skip to main content

# MediaWiki XML

This library contains a collection of utilities for efficiently processing MediaWiki’s XML database dumps. There are two important concerns that this module intends to address: complexity and performance of streaming XML parsing. This library enables memory efficent stream processing of XML dumps with a simple [iterator](https://pythonhosted.org/mwxml/iteration.html) strategy. This library also implements a distributed processing strategy (see [map()](https://pythonhosted.org/mwxml/map.html)) that enables parallel processing of many XML dump files at the same time.

## Example

>>> import mwxml
>>>
>>> dump = mwxml.Dump.from_file(open("dump.xml"))
>>> print(dump.site_info.name, dump.site_info.dbname)
Wikipedia enwiki
>>>
>>> for page in dump:
...     for revision in page:
...        print(revision.id)
...
1
2
3

## Author * Aaron Halfaker – https://github.com/halfak

## See also * http://dumps.wikimedia.org/ * http://community.wikia.com/wiki/Help:Database_download

Metadata

Release files for mwxml 0.3.8

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for mwxml 0.3.8
File Size Uploaded
mwxml-0.3.8.tar.gz 18.8 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for mwxml 0.3.8
File Interpreter ABI Platform
mwxml-0.3.8-py2.py3-none-any.whl Python 2, Python 3 none any Details

Total release size: 53.9 kB

Release files / mwxml-0.3.8.tar.gz

Download URL mwxml-0.3.8.tar.gz
Size 18.8 kB
Tags Source
SHA-256 checksum
How to use checksums
ca2232a97ea931e9bb24f85b54a491058c23c074576372e711246afac70616e0
BLAKE2b-256 checksum
How to use checksums
5ee0394649c0213f4f255afe6a9348761f1611ec7187dd42e5e8fac9068c7d7d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.1.1 pkginfo/1.5.0.1 requests/2.24.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.15.0 CPython/3.7.7

Release files / mwxml-0.3.8-py2.py3-none-any.whl

Download URL mwxml-0.3.8-py2.py3-none-any.whl
Size 35.1 kB
Tags Python 2 Python 3
SHA-256 checksum
How to use checksums
a5e0e540f8f9380e7eea8abacef988576cae0d7ec16c85d6f21a2d9973e86fba
BLAKE2b-256 checksum
How to use checksums
5a3d4341b7701dbd8a543b779f870c5e464b33c6e69eda2945ea8ea8fe78b56b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.1.1 pkginfo/1.5.0.1 requests/2.24.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.15.0 CPython/3.7.7

Release history Release notifications | RSS feed

This release

0.3.8 This release

2 release files

0.3.7

2 release files

0.3.6

2 release files

0.3.5

2 release files

0.3.4

2 release files

0.3.3

2 release files

0.3.2

2 release files

0.3.1

2 release files

0.3.0

2 release files

0.2.2

1 release file

0.2.1

2 release files

0.2.0

2 release files

0.1.1

2 release files

0.1.0

2 release files

0.0.4

2 release files

0.0.3

2 release files

0.0.2

2 release files

0.0.1

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page