microversion-parse
OpenStack microversion header parser
What it is and what it does
microversion_parse is a utility library for handling OpenStack microversion headers—the mechanism by which OpenStack APIs signal backward-compatible feature additions. It provides three core functions: get_version() extracts a version string from HTTP headers (supporting both standard 'OpenStack-API-Version' and legacy service-specific headers), parse_version_string() converts version strings into comparable Version tuples, and extract_version() combines both to validate that a requested version is in the service's supported list. It also includes MicroversionMiddleware, a WSGI middleware component that automatically negotiates microversions for incoming requests, returning appropriate HTTP error responses (406 for unsupported versions, 400 for malformed headers) and injecting the negotiated version into the WSGI environ.
The package is designed for OpenStack service operators and developers building microversion-aware APIs. Its single dependency is WebOb, a lightweight HTTP utility library. It supports Python 3.10 through 3.13 and carries no known security vulnerabilities. The aging maintenance status (last release 253 days ago) suggests the package is stable but not under active development.
Use it for:
- Validate and extract microversion numbers from incoming OpenStack API requests in a WSGI application.
- Wrap a microversion-aware WSGI app with middleware to automatically handle version negotiation and return appropriate HTTP responses.
- Parse and compare microversion strings to determine feature availability within an OpenStack service.
- Support both modern 'OpenStack-API-Version' headers and legacy service-specific headers like 'X-OpenStack-nova-api-version'.
- Translate the 'latest' keyword in version requests to the maximum supported version for a service.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
Parses and validates OpenStack microversion headers in HTTP requests, extracting version information for API versioning and providing WSGI middleware for automatic version negotiation.
Yes, if you are building or operating an OpenStack service that needs to handle microversion negotiation. The package is lightweight, has no security issues, and provides a standard way to parse and validate microversions. The aging maintenance status is not a blocker for stable, well-defined functionality, but verify that your OpenStack deployment's microversion requirements match the library's capabilities before adopting it.
Install
microversion-parse on PyPI
pip
pip install microversion-parseuv
uv add microversion-parsepoetry
poetry add microversion-parseInstalling microversion-parse
Before you install
Low install friction; pure Python wheel with a single runtime dependency on WebOb. Maintenance status is aging (253 days since last release), though the package has been stable since its 2016 inception and supports current Python versions through 3.13.
License in practice
Licensed under Apache-2.0 (permissive), allowing use in commercial and proprietary projects with minimal restrictions beyond attribution and liability disclaimers.
Quickstart
import microversion_parse
headers = {'openstack-api-version': 'compute 2.1'}
version = microversion_parse.get_version(headers, service_type='compute')
# Returns '2.1'
version_tuple = microversion_parse.parse_version_string('2.1')
# Returns comparable Version namedtuple
Requires Python 3.10 or later; WebOb must be installed as a runtime dependency.
Verify before relying
- Whether the package is actively maintained or in maintenance-only mode given the 253-day release gap.
- Real-world adoption rate and whether 113,051 monthly downloads reflect active OpenStack deployments or historical usage.
Package facts
| License | Apache-2.0 (permissive) |
| Python support | supports the current Python release (>=3.10) |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | 1 — WebOb |
| Maintenance | aging — 253 days since the last release |
| First released | |
| Downloads | 113,051/month — #12,351 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: microversion_parse-2.1.0-py3-none-any.whl
Tags
More WWW/HTTP packages
urllib3 is an HTTP client library that provides…
permissive · top 100 on PyPI
requestsRequests is a Python HTTP library that…
permissive · top 100 on PyPI
h11h11 is a pure-Python HTTP/1.1 protocol…
permissive · top 100 on PyPI
httpxHTTPX is a fully featured HTTP client library…
permissive · top 100 on PyPI
httpcoreA minimal low-level HTTP client library that…
permissive · top 100 on PyPI
aiohttpaiohttp is an async HTTP client and server…
permissive · top 100 on PyPI
oslo.middlewareoslo.middleware provides WSGI middleware…
permissive · top 15,000 on PyPI
WSMEWSME simplifies REST API development by letting…
permissive · top 15,000 on PyPI
keystonemiddlewareProvides authentication and authorization…
permissive · top 15,000 on PyPI
gunicorn_h1cFast HTTP/1.1 request and response parser for…
permissive · top 15,000 on PyPI
apig-wsgiWraps a WSGI application to run as an AWS…
permissive · top 15,000 on PyPI
oslo.contextoslo.context provides utilities to store and…
permissive · top 5,000 on PyPI
oslo.serviceoslo.service provides a framework for building…
permissive · top 15,000 on PyPI
WebObWebOb provides request and response objects…
permissive · top 5,000 on PyPI
repoze.whorepoze.who is an identification and…
permissive · top 15,000 on PyPI
versionsParses, compares, and validates semantic…
permissive · top 15,000 on PyPI