Release Version

Prepare Test PyPi / PyPi

  1. Add repositories to poetry config.

poetry config repositories.test-pypi https://test.pypi.org/legacy/
# pypi is already known by poetry by default
  1. Get your access tokens from Test PyPi and PyPi, respectively.

  2. Store tokens using poetry config.

poetry config pypi-token.test-pypi pypi-XXXXX...
poetry config pypi-token.pypi pypi-XXXXX...

Release Version to Test PyPi

First, check whether the project is ready for publication on Test PyPi.

  1. Update version, build the project, and publish the project at Test PyPi.

poetry version prerelease
poetry build
poetry publish -r test-pypi
  1. Create a new conda environment and install PyExperimenter from Test PyPi.

conda create -n pyexperimenter-release python=3.9
conda activate pyexperimenter-release
pip install -i https://test.pypi.org/simple/ --extra-index-url https://pypi.org/simple py-experimenter==<VERSION>
  1. Execute all example notebooks and check the outputs based on the new environment pyexperimenter-release. If anything does not work, fix it and repeat the steps above.

Release Version to PyPi

Warning

Check the publication on Test PyPi before publishing to PyPi!

  1. Update version and add according CHANGELOG information.

poetry version <major/minor/patch>
  1. Create a pull request from develop to main and merge it (not squash merge).

  2. Create a tag with the according version number for that merge commit.

  3. Create a new release for that tag with the version number as title and the latest changelog additions as content. With pressing the button Publish release the requested files will be attached automatically.

  4. Build the project and publish the project at PyPi.

poetry build
poetry publish
  1. Check PyPi version.