PyPI Release Checklist¶
First-Time Setup (One-Time)¶
-
Create a PyPI account at pypi.org if you don't have one.
-
Go to your PyPI account > Publishing > Add a new pending publisher.
-
Fill in the form:
- PyPI Project Name: Your package name (e.g.,
my-package) - Owner: Your GitHub username or organization
- Repository name: Your repo name
- Workflow name:
publish.yml -
Environment name:
pypi -
In your GitHub repo, go to Settings > Environments > New environment. Name it
pypi. Optionally add required reviewers and restrict deployment tov*tags. -
Push your first tag to trigger the publish (see below).
Every Release¶
-
Write your release notes in
CHANGELOG/vX.Y.Z.mdand commit: -
Bump the version and commit:
-
Push, then tag and push the tag:
-
GitHub Actions builds, signs with Sigstore, and publishes to PyPI automatically.
Troubleshooting¶
If the publish fails:
- Check that your PyPI trusted publisher settings match your workflow exactly
- Verify the tag format matches what PyPI expects (e.g.,
v1.0.0) - Look at the GitHub Actions logs for detailed error messages