Maintainer release guide¶
Releases use PyPI Trusted Publishing. There is no long-lived PyPI API token in GitHub Actions.
One-time repository setup¶
- Enable GitHub Pages with GitHub Actions as its source.
- Create a protected
pypienvironment. - In PyPI, add a Trusted Publisher for repository
ilysenko/django-fastapi, workflowrelease.yml, environmentpypi. - Enable secret scanning, push protection, private vulnerability reporting,
Dependabot alerts, and branch protection for
main. - Require CI before merging external pull requests. Disable force pushes and branch deletion.
Release checklist¶
- Update
CHANGELOG.mdandproject.versioninpyproject.toml. - Merge the tested snapshot to
mainand wait for every required check. - Tag the exact commit as
vX.Y.Zand push the tag. - The release workflow compares the tag to package metadata, builds a fresh wheel and sdist, checks both, records SHA-256 hashes, creates build provenance, and publishes through OIDC.
- Install the published version in a new Django project and run the five-minute quickstart.
Never rebuild or manually upload artifacts after the workflow completes. A different build with the same version cannot be meaningfully audited.