Skip to content

Creating a new release

Pablo Prietz edited this page Feb 8, 2023 · 1 revision

New releases can be triggered by pushing an annotated git tag to Github.

git tag -a $TAGNAME
git push origin $TAGNAME

The $TAGNAME should be the version and follow the PEP 440 version scheme (no leading v), e.g. 2.0.1.

Implementation

Pushing the tag triggers the release step of the Github Action. This, in turn, runs tox -e release which publishes the build artifacts on PyPI and as Github release.

For pure Python packages, the build happens as part of the release step. For packages with binary extensions, the build process should happen independently of the release. As such, the build step needs to upload the artifacts and the release step needs to download them, before being able to publish them. An example workflow can be found here.

Clone this wiki locally