pyproject-metadata
PEP 621 metadata parsing
Decision gist · record as of 2026-08-14
Yes. This is a foundational tool for Python build backends and packaging infrastructure. It has no security vulnerabilities, minimal dependencies, active maintenance, and a permissive license. Install it if you're building a backend, validating project metadata, or need to generate core metadata files from structured data.AI-flagged interpretation of the facts on this page — verify before relying
Before you install
- Requires Python 3.8+; input must already be a parsed dict (TOML parsing is caller's responsibility).
- Low friction: single runtime dependency (packaging), pure Python wheel, actively maintained with recent release.
License · maintenance · safety
MIT (permissive) — MIT license permits unrestricted use, modification, and distribution in commercial and private projects.
last release 2026-07-04 (41 days) · last repo commit 2026-08-13 · 43 stars
0 known vulnerabilities (OSV.dev, 2026-08-14) · 14,063,548 downloads/mo, #1,249 on PyPI
Alternatives
Verify before relying
from pyproject_metadata import StandardMetadata
parsed = {...} # dict from tomli or similar
metadata = StandardMetadata.from_pyproject(parsed)
pkg_info = metadata.as_rfc822()
print(str(pkg_info))- Whether SPDX license canonicalization (packaging 24.2+) is mandatory or optional for typical use.
- Performance characteristics when processing large or deeply nested metadata structures.
- Compatibility guarantees across future PEP 621 revisions beyond METADATA 2.4.
What it is and what it does
pyproject-metadata is a dataclass-based validator and transformer for Python project metadata. It takes a parsed dictionary representing the [project] table from pyproject.toml, validates it against PEP 621 and related standards, and generates RFC 822-formatted core metadata suitable for distribution (e.g., PKG-INFO files). It does not parse TOML itself—that responsibility stays with the caller—but handles all the structural validation, normalization, and serialization that build backends and packaging tools need.
The package supports modern metadata standards including dynamic metadata (METADATA 2.2+), SPDX license expressions (METADATA 2.4+), and flexible error reporting. It can collect all validation errors at once rather than failing on the first one, making it useful for build systems that want to report comprehensive feedback. It also provides utilities to map between pyproject.toml field names and their corresponding metadata fields, and can validate classifiers against the trove_classifiers library if installed.
Use it for
- Build backends (like hatchling or flit) validating and serializing project metadata during package builds.
- Packaging tools that need to generate or inspect PKG-INFO files without re-parsing TOML.
- CI/CD pipelines validating pyproject.toml metadata structure before publishing to PyPI.
- Tools that need to convert between pyproject.toml [project] and core metadata formats programmatically.
- Build systems implementing dynamic metadata, where some fields are computed at build time.
Worth the install?
AI-flagged interpretation of the facts on this page. Verify before relying on it.
Yes.
This is a foundational tool for Python build backends and packaging infrastructure. It has no security vulnerabilities, minimal dependencies, active maintenance, and a permissive license. Install it if you're building a backend, validating project metadata, or need to generate core metadata files from structured data.
Install
pyproject-metadata on PyPI
Before you install
Low friction: single runtime dependency (packaging), pure Python wheel, actively maintained with recent release.
Requires Python 3.8+; input must already be a parsed dict (TOML parsing is caller's responsibility).
License in practice
MIT license permits unrestricted use, modification, and distribution in commercial and private projects.
Quickstart
from pyproject_metadata import StandardMetadata
parsed = {...} # dict from tomli or similar
metadata = StandardMetadata.from_pyproject(parsed)
pkg_info = metadata.as_rfc822()
print(str(pkg_info))
Verify before relying
- Whether SPDX license canonicalization (packaging 24.2+) is mandatory or optional for typical use.
- Performance characteristics when processing large or deeply nested metadata structures.
- Compatibility guarantees across future PEP 621 revisions beyond METADATA 2.4.
Package facts
| License | MIT permissive |
| Python support | Supports the current Python release >=3.8 |
| Install friction | Low. Pure-Python wheel |
| Runtime dependencies | 1 packagepackaging |
| Maintenance | Actively maintained 41 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 14,063,548 / month, #1,249 on PyPI 30-day window, as of 2026-08-14 |
| Known vulnerabilities | None known OSV.dev, checked 2026-08-14 |
| Classifiers | Programming Language :: Python :: 3Programming Language :: Python :: 3 :: OnlyProgramming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.13Programming Language :: Python :: 3.14Programming Language :: Python :: 3.15Programming Language :: Python :: 3.8Programming Language :: Python :: 3.9 |
Evidence: pyproject_metadata-0.12.1-py3-none-any.whl
Tags
Let your AI agent find packages like this
Example. Real query, live index.
You found this page by searching. An agent finds it by wishing: SkillFed indexes 14,416 PyPI packages by what they can do, searchable in plain language.
wish › “pyproject.toml metadata validation”
- pyproject-metadataValidates and transforms pyproject.toml [project] metadata into PEP…
- pyproject-tomlParses and validates Python project metadata from pyproject.toml…
- validate-pyprojectValidates pyproject.toml files against JSON Schema definitions to…
Give your agent the search over MCP, or paste the wish link into any chat.
More Build Tools packages
Provides reusable utilities for Python packaging interoperability, including version handling, specifiers, markers, requirements, tags, and metadata parsing according to standards like PEP 440 and PEP 425.
Wraps any iterable to display a real-time progress bar in the terminal or Jupyter notebook, showing iteration count, elapsed time, and estimated time remaining.
pip is the standard installer for Python packages, enabling you to download and install packages from the Python Package Index and other indexes into your Python environment.
Hatchling is a standards-compliant Python build backend that handles packaging, metadata, and distribution of Python projects when configured in a project's pyproject.toml file.
Generates Python gRPC service stubs and message classes from Protocol Buffer definitions, enabling developers to build gRPC clients and servers.
pre-commit is a framework for installing and running git hooks written in any language before commits are made, automating code quality and validation checks across multi-language projects.
Install it if your team needs consistent, automated validation at commit time.
See also pyproject-toml · trove-classifiers · validate-pyproject · pyproject-parser · pkginfo2 · pdm-pep517 · pdm-backend · sphinx-pyproject · dist-meta · pyroma