Publishing a release

This page describes the steps required to author a release of GWpy.

Notes:

  • gwpy uses the stable mainline branching model for releases

  • all release numbers must follow Semantic Versioning 2 and include major, minor, and patch numbers, e.g. X.Y.Z rather than 1.0 or just 1

Step-by-step

  1. If this is a bug-fix release, just check out that branch:

    git checkout release/X.Y.x
    
  2. Update the copyright:

    python -c "from setup_utils import update_all_copyright; update_all_copyright($(date +%Y))"
    git commit -S -m "Updated copyright for release" .
    
  3. Publish the release, allowing CI to run, and others to see it:

    git push -u origin master
    

    for major/minor releases, or

    for bug-fix releases

  4. Wait patiently for the continuous integration to finish

  5. Announce the release and ask for final contributions

  6. Tag the release:

    git tag --sign vX.Y.Z
    
  7. Create a maintenance branch (major/minor releases only):

    git branch release/X.Y.x
    
  8. Publish everything:

    # push maintenance branch
    git push --signed=if-asked origin release/X.Y.x
    # push master branch
    git push --signed=if-asked origin master
    # push new tag
    git push --signed=if-asked origin vX.Y.Z
    
  9. Draft a release on GitHub

  10. Publish the release documentation

    This is done from the LDAS computing centre at Caltech:

    cd /home/duncan.macleod/gwpy-nightly-build/
    bash release-build.sh X.Y.Z
    

    Once that is complete (~20 minutes), a few manual updates must be made:

    cd /home/duncan.macleod/gwpy-nightly-build/gwpy.github.io/docs
    unlink stable && ln -s X.Y.Z stable
    sed -i 's/0.9.9/X.Y.Z/g' index.html
    

    The final command should be modified to replace the previous release ID with the current one.

    Then:

    git commit --gpg-sign --message="X.Y.Z: release docs"
    git push --signed=if-asked  # <- this step needs an SSH key
    

    It should take ~5 minutes for the release documentation to actually appear on https://gwpy.github.io/docs/

Linked updates

Zenodo

Creating a new release on GitHub will automatically trigger a new DOI on https://zenodo.org.

Distributing the new release package

Package distributions for PyPI, Conda, Debian, and RHEL are done manually:

PyPI

To create a new release on PyPI:

rm -rf dist/
git checkout vX.Y.Z
python setup.py sdist bdist_wheel
gpg --armor --detach-sign dist/gwpy-*.tar.gz
twine upload dist/gwpy-*

Conda

Once the PyPI upload has completed, the conda-forge bot will automatically open a pull request to conda-forge/gwpy-feedstock. Just double-check that the dependencies and tests are up-to-date, then merge.

Debian/RHEL

  • Upload the source tarball to software.ligo.org

  • Open a new request to sccb/requests to announce the new release and request package build and deployment.