This release is a pre-release and may not be stable for production use.
ZenodoZipDownloader
A Python package to download and extract selected files from ZIP archives in Zenodo records, with pattern matching, CRC32 integrity checks, and robust retry logic.
Features
- Download files from Zenodo records using DOI or record URL
- Filter ZIP files and inner files using glob patterns
- Download only a subset of files if desired
- CRC32 integrity check for downloaded files
- Retry logic for network and file operations
- Command-line interface (CLI)
Installation
pip install zenodozipdownloader
Or from source:
git clone https://github.com/yourusername/zenodozipdownloader.git
cd zenodozipdownloader
pip install .
Requirements
- Python 3.10 or newer
- Network access to
https://zenodo.org/ - Optional:
tqdmfor download progress (see below)
Optional progress bar
The package can show download progress if tqdm is available. Install it alongside the downloader with:
pip install zenodozipdownloader[tqdm]
Usage
As a Python module
# [optional] set logging level to INFO for more verbose output
import logging
logging.basicConfig(level=logging.INFO)
from zenodozipdownloader import ZenodoZipDownloader
doi = "10.5281/zenodo.5423457"
downloader = ZenodoZipDownloader(doi, download_dir="zenodo_downloads")
downloaded_files = downloader.download(zip_pattern="*.zip", inner_pattern="*tubulin*.mat")
for path in downloaded_files:
print(f"Saved: {path}")
By default:
- Extracted files stay inside the chosen
download_dir; unsafe ZIP paths are skipped. - All files are downloaded unless you provide
inner_pattern. - Downloads retry up to three times and validate CRC32 checksums.
As a CLI tool
zenodozipdownloader 10.5281/zenodo.5423457 --download_dir zenodo_downloads --zip_pattern "*.zip" --inner_pattern "*tubulin*.mat"
Run zenodozipdownloader --help for the full CLI reference. It shares defaults with the Python API; omit --first_n_zip and --first_n_inner to process every match.
Arguments
doi: Zenodo DOI or record URL--download_dir: Directory to save downloaded files (default: current directory)--zip_pattern: Glob pattern for ZIP files in the record (default:*.zip)--inner_pattern: Glob pattern for files inside ZIPs (default: all)--first_n_zip: Only process the first N matching ZIP files (default: all)--first_n_inner: Only download the first N matching files within each ZIP (default: all)
Testing
To run the integration tests and check code coverage:
pip install pytest pytest-cov
pytest --cov=zenodozipdownloader tests/
License
MIT License
Metadata
Release files for zenodozipdownloader 0.1.0a1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| zenodozipdownloader-0.1.0a1.tar.gz | 11.2 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| zenodozipdownloader-0.1.0a1-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 19.5 kB
Release files / zenodozipdownloader-0.1.0a1.tar.gz
| Download URL | zenodozipdownloader-0.1.0a1.tar.gz |
|---|---|
| Size | 11.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
ab9a7c8e5c98fd85ef4e4fe81531f697983d2b339e6c27fefc16789e2ba070e2
|
|
BLAKE2b-256 checksum How to use checksums |
259158e09f5918810b5e4ce1e3a474608588747d0070eab4c7822c3f34f4c52c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Dec 29, 2025.
Transparency logRelease files / zenodozipdownloader-0.1.0a1-py3-none-any.whl
| Download URL | zenodozipdownloader-0.1.0a1-py3-none-any.whl |
|---|---|
| Size | 8.3 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
6a518bd0b56e05b453f14c6877d7dc53a2d4ee4eb77ac30fdef9c05317a41656
|
|
BLAKE2b-256 checksum How to use checksums |
e08d427f3dcad4f223003078d60a71cf539ba41cb593cb2ffd68bb3f64299c61
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Dec 29, 2025.
Transparency log