Releasing

  1. Update the version in these two locations:

    • docs/source/conf.py

    • pyproject.toml

  2. Create a new branch and open a PR on GitHub which will run all actions

  3. Apply any fixes to make the actions pass

  4. Clean your local directory. This will prevent any files not under source control from being built into the distribution.

    git clean -f -x 
    
  5. Build the wheel and source distributions:

    python setup.py clean bdist_wheel sdist
    
  6. Upload to Test PyPi

    twine upload -r testpypi dist/* --verbose
    
  7. Upload to PyPi

    twine upload dist/*
    
  8. Add a git tag

    git tag -a v<major>.<minor>.<patch> -m "version <major>.<minor>.<patch>"
    git push origin <tagname>
    
  9. Merge PR