Developer Notes#

Maintenance and manual processes

Change Log Maintenance#

For now, development PRs should normally include additions in the common changelog file docs/change_log.rst.

For now, we aren’t categorising changes, but intend to include a combination of release-page notes and a simple list of PRs.

Documentation build#

  • For a full docs-build
    • a simple $ make html will do for now

    • The docs/Makefile wipes the API docs and invokes sphinx-apidoc for a full rebuild

  • Results are then available at docs/_build/html/index.html
    • The above is just for local testing if required

    • We have automatic builds for releases and PRs via ReadTheDocs

Release actions#

  1. Cut a release on GitHub : this triggers a new docs version on [ReadTheDocs](https://readthedocs.org/projects/ncdata/)

  2. Build the distribution

    1. if needed, get build

    2. run $ python -m build

  3. Push to PyPI

    1. if needed, get twine

    2. run
      • $ python -m twine upload --repository testpypi dist/*

      • this uploads to TestPyPI

    3. create a new env with test dependencies * $ conda create -n ncdtmp python=3.11 iris xarray filelock requests pytest pip * ( N.B. ‘filelock’ and ‘requests’ are _test_ dependencies of iris )

    4. install the new package with * $ pip install --index-url https://test.pypi.org/simple/ ncdata * ..and run tests

    5. if that checks OK,
      • remove --repository testpypi and repeat “upload” step (2)

      • –> uploads to “real” PyPI

    6. repeat “pip install” step (4) * but removing the --index-url * ..to check that pip install ncdata now finds the new version

  4. Update conda to source the new version from PyPI

    1. create a PR on the ncdata feedstock

    2. update :
    3. get PR merged * wait a few hours.. * check that the new version appears in the output of $ conda search ncdata