Skip to content

Cap hatchling <1.27 so wheels publish to PyPI - #4

Merged
jar-ben merged 1 commit into
mainfrom
jaroslav/fix-metadata-version
Aug 28, 2026
Merged

jar-ben merged 1 commit into
mainfrom
jaroslav/fix-metadata-version

Conversation

@jar-ben

@jar-ben jar-ben commented Aug 28, 2026

Copy link
Copy Markdown
Contributor

hatchling >=1.27 stamps wheels with Metadata-Version 2.5 (PEP 639
license-expression / license-file fields). The twine bundled in the
pinned pypa/gh-action-pypi-publish image cannot validate 2.5, so the
v0.2.0 release built successfully but failed at the publish step with
"InvalidDistribution: '2.5' is not a valid metadata version" — nothing
reached PyPI.

Capping the build backend below 1.27 emits Metadata-Version 2.3, which
that action's twine and PyPI both accept. Verified locally: twine check
passes under packaging==24.0 (which reproduced the failure on 2.5).

@jar-ben
jar-ben requested a review from shellygr August 28, 2026 10:47
@jar-ben
jar-ben merged commit 194a41a into main Aug 28, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants