Releases: eth-library/oaipmh
v3.2.0 — Typed HTTP retry exceptions
Added
RateLimitedError,ServiceUnavailableError, andNetworkErrorexception classes for typed handling of HTTP 429, 503, and transport-level failures. All three preserve existingexceptcatch sites via inheritance.max-inline-sleepretry-policy key (default 300 s), configurable viacustom_retry_policy; a 503 whoseRetry-Afterexceeds the cap raises instead of sleeping inline.
Changed
- HTTP 429 raises
RateLimitedErrorimmediately instead of falling through as a rawHTTPError. urllib.error.URLErroris caught and re-raised asNetworkError.- Replace
e.hdrswithe.headersinretrieveFromUrlWaiting(). - Chain re-raised exceptions with
raise ... frominclient.py,server.py, anddatestamp.pyso tracebacks show the original cause (RuffB904/ PEP 3134). - Build the published wheel inside the project's Nix flake devShell (
publish.yml). Pure-Python source semantics unchanged; published artifact bytes may differ across releases due to build-toolchain provenance. - Development tooling and CI infrastructure improvements:
lint:Add Ruff as the Python lint and format gate viapre-commit(#18)style:Repo-wideruff formatpass (#20)chore:pre-commithook forflake.lockdrift detection (#25)ci:Nix flake devShells for CI and publish workflows (#22)ci:Centralise Nix-store and uv-wheel caches via composite Actions (#24)refactor:Splitflake.nixintoflake-partsmodules;nixfmt-rfc-styleformatting andtreefmthook (#31)
Deprecated
- Passing 429 or 503 in a caller-supplied
expected-errcodesset now emitsDeprecationWarning; catch the typed exceptions instead.
v3.1.0 — Python 3.14 support
Minor release adding Python 3.14 to the supported matrix. No API or runtime changes — existing 3.0.x consumers can upgrade without code changes.
Added
- Python 3.14 support. Added to the
pyproject.tomltrove classifiers and to the CI matrix; the test suite runs green on CPython 3.10 – 3.14.
Security
- GitHub Actions in
ci.ymlandpublish.ymlpinned to full commit SHAs instead of mutable tags.
Maintenance (no downstream impact)
- Nix development shell bumped to Python 3.14, with
uvpinned to the Nix-provided interpreter. - Dependabot configuration added for GitHub Actions and
uvdependency updates.
Full changelog: https://github.com/eth-library/oaipmh/blob/v3.1.0/CHANGELOG.md
Compare: v3.0.1...v3.1.0
v3.0.1 — Embed README as PyPI long description
Patch release fixing the empty project body on the PyPI page for oaipmh 3.0.0. Pure packaging-metadata fix — no code or API changes.
Fixed
- Embed
README.mdas the project's long description on PyPI. The PEP 621readmefield was missing frompyproject.toml, so theoaipmh 3.0.0page on PyPI showed an empty body. No code or API changes; this is a packaging-metadata-only fix.
Full changelog: https://github.com/eth-library/oaipmh/blob/v3.0.1/CHANGELOG.md
Compare: v3.0.0...v3.0.1
v3.0.0 — Modernized maintenance fork of infrae/pyoai
oaipmh 3.0.0 is the first release of the ETH Library's maintenance fork of infrae/pyoai. The PyPI distribution has been renamed pyoai → oaipmh; the import path (from oaipmh import ...) and the public API are unchanged, so existing consumers only need to swap the dependency name.
Why this fork
pyoai is a long-standing OAI-PMH client and server library used by many digital-library, archive, and GLAM systems to harvest and expose bibliographic metadata. Upstream went quiet in March 2022, and without an active maintainer the library has been falling behind modern Python, so we picked it up to keep it going.
Full change detail follows; see CHANGELOG.md for historical entries.
[3.0.0] — 2026-04-15
First release under the oaipmh distribution name on PyPI. This release marks the maintenance fork from infrae/pyoai and brings the codebase onto modern Python packaging and tooling. The public API and the from oaipmh import ... import path are unchanged.
Breaking Changes
- Renamed PyPI distribution from
pyoaitooaipmh. Existing consumers must update their dependency declarations; no application code changes are required. - Minimum supported Python version raised to 3.10. Python 2 and Python 3.9 and earlier are no longer supported.
- Removed the
sixdependency; the package now relies exclusively on native Python 3 APIs.
Added
- PEP 621 metadata in
pyproject.tomlwith Hatchling as the build backend. uv.lockfor reproducible dependency resolution.uv-based GitHub Actions CI covering Python 3.10 – 3.13.- GitHub Actions workflow (
publish.yml) for automated PyPI publishing via Trusted Publishing (OIDC; no long-lived tokens stored in the repository). - Reproducible development environment via a Nix flake and
direnvintegration. pytestconfiguration replacing the legacyruntests.shentry point.CONTRIBUTING.mdwith development setup, commit conventions, and the release process.CHANGELOG.md(this file), supersedingHISTORY.txt.ETH Library — Data Science and Research Support <[email protected]>maintainer entry alongside the existing Jaime Cardozo entry.
Changed
- Build backend migrated from legacy
setup.py/setup.cfgto Hatchling viapyproject.toml. - Development status classifier raised from
4 - Betato5 - Production/Stable. - Version jumped from
2.5.2preto3.0.0to reflect the breaking distribution rename and the Python version floor. - README rewritten and expanded; converted from reStructuredText (
README.rst) to Markdown (README.md). - License file renamed from
LICENSE.txttoLICENSEand prepended with an ETH Zurich copyright notice alongside the original Infrae notice. - Wheel and sdist contents scoped via explicit
tool.hatch.buildinclude/exclude lists, so consumers no longer receive test fixtures or local development files. - Bare imports inside the package converted to relative imports.
Fixed
- Replaced deprecated
datetime.utcnow()with timezone-awaredatetime.now(timezone.utc)equivalents (Python 3.12+ deprecation). - Replaced
lxml.etree.XPath.evaluate()calls with direct callable syntax for compatibility withlxml5.x. - Replaced
unicode()withstr()for Python 3 compatibility. - Replaced
pkg_resourceswithimportlib.metadatafor distribution version lookup. - Replaced removed unittest assertion aliases dropped in Python 3.12.
- Removed the
unittest.makeSuitehelper, which was dropped in Python 3.13. - Renamed the internal test helper
TestErrortoFakeRequestErrorto avoid pytest'sPytestCollectionWarningon classes prefixed withTest.
Removed
- Python 2 compatibility shims across the package and tests.
sixdependency.- Legacy packaging files:
setup.py,setup.cfg,tox.ini,MANIFEST.in, and.travis.yml. runtests.sh(replaced bypytest).- Non-functional Python 2 data generation scripts.
- Outdated
doc/directory. - Legacy Mercurial files.
HISTORY.txt(content migrated to this file).