Skip to content

Release checklist

PyPI Release Checklist

Before Your First Release

You better visit PyPI to make sure your package name is unused.

For Every Release

  1. Make some pull requests, merge all changes from feature branch to master/main.

  2. Update CHANGELOG.md manually. Make sure it follows the Keep a Changelog standard. Be noticed that GitHub workflow will read changelog and extract release notes automatically.

  3. Commit the changelog changes:

1
2
git add CHANGELOG.md
git commit -m "Changelog for upcoming release 0.1.1."
  1. Update version number and automatically create a commit, tag(can also be patch or major).
1
poetry run bump2version patch
  1. Run the tests locally for insurance:
1
poetry run tox
  1. Push these commits to master/main:
1
git push

Before proceeding to the next step, please check workflows triggered by this push have passed.

  1. Push the tags(created by bump2version) to master/main, creating the new release on both GitHub and PyPI:
1
git push --tags

Only tag name started with 'v'(lower case) will leverage GitHub release workflow.

  1. If there is a need to manually create tag or re-push under the same tag:

This is delete and re-create the tag locally.

1
2
git tag -d {tagname}
git tag {tagname}

Then follow by deleting and re-creating the tag remotely.

1
2
git push origin :{tagname}
git push origin {tagname}

Finally update local repository with the updated tag

1
git fetch --tags
  1. Check the PyPI listing page to make sure that the README, release notes, and roadmap display properly. If tox test passed, this should be ok, since we have already run twine check during tox test.

About This Checklist

This checklist is adapted from https://cookiecutter-pypackage.readthedocs.io/en/latest/pypi_release_checklist.html.

It assumes that you are using all features of Cookiecutter PyPackage.


Last update: 2021-12-20
Back to top