diff --git a/.coveragerc b/.coveragerc
deleted file mode 100644
index 81a40161..00000000
--- a/.coveragerc
+++ /dev/null
@@ -1,16 +0,0 @@
-#
-# .coveragerc to control coverage.py
-#
-
-[run]
-branch = True
-omit =
- setup.py
- iris_grib/tests/*
-
-
-[report]
-exclude_lines =
- pragma: no cover
- def __repr__
- if __name__ == .__main__.:
diff --git a/.git-blame-ignore-revs b/.git-blame-ignore-revs
new file mode 100644
index 00000000..595c9be9
--- /dev/null
+++ b/.git-blame-ignore-revs
@@ -0,0 +1,5 @@
+# adopt ruff (#430)
+669a5daf1433a99766f0ecbf1513758f3c97e6d6
+
+# migrate iris_grib to src/iris_grib (#450)
+e57dac079591b978806e55c7450b61d62b9342f5
diff --git a/.github/dependabot.yml b/.github/dependabot.yml
new file mode 100644
index 00000000..6ce59a36
--- /dev/null
+++ b/.github/dependabot.yml
@@ -0,0 +1,23 @@
+# Reference:
+# - https://docs.github.com/en/code-security/supply-chain-security/keeping-your-dependencies-updated-automatically/keeping-your-actions-up-to-date-with-dependabot
+# - https://docs.github.com/en/code-security/dependabot/dependabot-version-updates/configuration-options-for-the-dependabot.yml-file#groups
+
+version: 2
+updates:
+
+ - package-ecosystem: "github-actions"
+ directory: "/"
+ schedule:
+ # Check later in the week - the upstream dependabot check in `workflows` runs deliberately early in the week.
+ # Therefore allowing time for the `workflows` update to be merged-and-released first.
+ interval: "weekly"
+ day: "thursday"
+ time: "01:00"
+ timezone: "Europe/London"
+ groups:
+ dependencies:
+ patterns:
+ - "*"
+ labels:
+ - "New: Pull Request"
+ - "Bot"
diff --git a/.github/workflows/ci-linkchecks.yml b/.github/workflows/ci-linkchecks.yml
new file mode 100644
index 00000000..1771ec59
--- /dev/null
+++ b/.github/workflows/ci-linkchecks.yml
@@ -0,0 +1,50 @@
+name: Linkcheck
+
+on:
+ workflow_dispatch:
+ schedule:
+ - cron: "00 06 * * *"
+
+concurrency:
+ group: ${{ github.workflow }}-${{ github.ref }}
+ cancel-in-progress: true
+
+jobs:
+ linkChecker:
+ runs-on: ubuntu-latest
+ permissions:
+ issues: write # required for peter-evans/create-issue-from-file
+
+ steps:
+ - uses: actions/checkout@v6
+ with:
+ fetch-depth: 0
+ persist-credentials: false
+
+ - name: Link Checker
+ id: lychee
+ uses: lycheeverse/lychee-action@8646ba30535128ac92d33dfc9133794bfdd9b411
+ with:
+ token: ${{secrets.GITHUB_TOKEN}}
+ fail: false
+ args: |
+ --verbose
+ --max-concurrency 1
+ './docs/**/*.rst'
+ './lib/**/*.py'
+
+ - name: Create Issue From File
+ if: ${{ fromJSON(steps.lychee.outputs.exit_code) != 0 }}
+ uses: peter-evans/create-issue-from-file@fca9117c27cdc29c6c4db3b86c48e4115a786710
+ with:
+ title: Link Checker Report
+ content-filepath: ./lychee/out.md
+ labels: |
+ Bot
+ Type: Documentation
+ Type: Bug
+
+ - name: Fail Workflow On Link Errors
+ if: ${{ fromJSON(steps.lychee.outputs.exit_code) != 0 }}
+ run:
+ exit ${{ fromJSON(steps.lychee.outputs.exit_code) }}
diff --git a/.github/workflows/ci-manifest.yml b/.github/workflows/ci-manifest.yml
new file mode 100644
index 00000000..2454ece8
--- /dev/null
+++ b/.github/workflows/ci-manifest.yml
@@ -0,0 +1,25 @@
+name: ci-manifest
+
+on:
+ pull_request:
+ branches:
+ - "*"
+
+ push:
+ branches-ignore:
+ - "auto-update-lockfiles"
+ - "pre-commit-ci-update-config"
+ - "dependabot/*"
+
+ workflow_dispatch:
+
+concurrency:
+ group: ${{ github.workflow }}-${{ github.ref }}
+ cancel-in-progress: true
+
+permissions: {}
+
+jobs:
+ manifest:
+ name: "check-manifest"
+ uses: scitools/workflows/.github/workflows/ci-manifest.yml@1f2141422a63321a32575ddd186e53acff12550c
diff --git a/.github/workflows/ci-template-check.yml b/.github/workflows/ci-template-check.yml
new file mode 100644
index 00000000..f5a4e306
--- /dev/null
+++ b/.github/workflows/ci-template-check.yml
@@ -0,0 +1,20 @@
+# Checks if a PR makes any changes that ought to be shared via templating.
+# See the called workflow in the scitools/workflows repo for more details.
+
+name: ci-template-check
+
+on:
+ pull_request_target:
+ branches:
+ - main
+
+permissions: {}
+
+jobs:
+ prompt-share:
+ uses: scitools/workflows/.github/workflows/ci-template-check.yml@1f2141422a63321a32575ddd186e53acff12550c
+ secrets:
+ AUTH_APP_ID: ${{ secrets.AUTH_APP_ID }}
+ AUTH_APP_PRIVATE_KEY: ${{ secrets.AUTH_APP_PRIVATE_KEY }}
+ with:
+ pr_number: ${{ github.event.pull_request.number }}
diff --git a/.github/workflows/ci-tests.yml b/.github/workflows/ci-tests.yml
new file mode 100644
index 00000000..eab3158e
--- /dev/null
+++ b/.github/workflows/ci-tests.yml
@@ -0,0 +1,138 @@
+# reference:
+# - https://github.com/actions/cache
+# - https://github.com/actions/checkout
+# - https://github.com/marketplace/actions/setup-miniconda
+
+name: ci-tests
+
+on:
+ push:
+ branches:
+ - "main"
+ - "v*x"
+ tags:
+ - "v*"
+ pull_request:
+ branches:
+ - "*"
+ workflow_dispatch:
+
+concurrency:
+ group: ${{ github.workflow }}-${{ github.ref }}
+ cancel-in-progress: true
+
+jobs:
+ tests:
+ name: "${{ matrix.session }} py${{ matrix.python-version }} [${{ matrix.iris-source }}]"
+
+ runs-on: ${{ matrix.os }}
+
+ defaults:
+ run:
+ shell: bash -l {0}
+
+ strategy:
+ fail-fast: false
+ matrix:
+ os: ["ubuntu-latest"]
+ python-version: ["3.14"]
+ session: ["doctest"]
+ iris-source : ["conda-forge"]
+ include:
+ - os: "ubuntu-latest"
+ python-version: "3.14"
+ session: "tests"
+ iris-source: "conda-forge"
+ coverage: "--coverage"
+ - os: "ubuntu-latest"
+ python-version: "3.14"
+ session: "tests"
+ iris-source: "source"
+ - os: "ubuntu-latest"
+ python-version: "3.13"
+ session: "tests"
+ iris-source: "conda-forge"
+ - os: "ubuntu-latest"
+ python-version: "3.12"
+ session: "tests"
+ iris-source: "conda-forge"
+
+ env:
+ IRIS_TEST_DATA_VERSION: "2.24"
+ ENV_NAME: "ci-tests"
+
+ steps:
+ - name: "checkout"
+ uses: actions/checkout@v6
+
+ - name: "environment configure"
+ env:
+ # Maximum cache period (in weeks) before forcing a cache refresh.
+ CACHE_WEEKS: 2
+ run: |
+ echo "CACHE_PERIOD=$(date +%Y).$(expr $(date +%U) / ${CACHE_WEEKS})" >> ${GITHUB_ENV}
+ echo "LOCK_FILE=requirements/locks/py$(echo ${{ matrix.python-version }} | tr -d '.')-linux-64.lock" >> ${GITHUB_ENV}
+
+ - name: "data cache"
+ uses: ./.github/workflows/composite/iris-data-cache
+ with:
+ cache_build: 0
+ env_name: ${{ env.ENV_NAME }}
+ version: ${{ env.IRIS_TEST_DATA_VERSION }}
+
+ - name: "conda package cache"
+ uses: ./.github/workflows/composite/conda-pkg-cache
+ with:
+ cache_build: 0
+ cache_period: ${{ env.CACHE_PERIOD }}
+ env_name: ${{ env.ENV_NAME }}
+
+ - name: "conda install"
+ uses: conda-incubator/setup-miniconda@v4
+ with:
+ miniforge-version: latest
+ channels: conda-forge,defaults
+ activate-environment: ${{ env.ENV_NAME }}
+ auto-update-conda: false
+ use-only-tar-bz2: true
+
+ - name: "conda environment cache"
+ uses: ./.github/workflows/composite/conda-env-cache
+ with:
+ cache_build: 0
+ cache_period: ${{ env.CACHE_PERIOD }}
+ env_name: ${{ env.ENV_NAME }}
+ install_packages: "cartopy nox pip"
+
+ - name: "conda info"
+ run: |
+ conda info
+ conda list
+
+ - name: "cartopy cache"
+ uses: ./.github/workflows/composite/cartopy-cache
+ with:
+ cache_build: 0
+ cache_period: ${{ env.CACHE_PERIOD }}
+ env_name: ${{ env.ENV_NAME }}
+
+ - name: "nox cache"
+ uses: ./.github/workflows/composite/nox-cache
+ with:
+ cache_build: 0
+ env_name: ${{ env.ENV_NAME }}
+ lock_file: ${{ env.LOCK_FILE }}
+
+ - name: "iris-grib ${{ matrix.session }}"
+ env:
+ IRIS_SOURCE: ${{ matrix.iris-source }}
+ PY_COLORS: 1
+ PY_VER: ${{ matrix.python-version }}
+ run: |
+ nox --session ${{ matrix.session }} -- ${{ matrix.coverage }} --test-data-dir ${HOME}/iris-test-data/test_data
+
+ - name: "upload coverage report"
+ if: ${{ matrix.coverage }}
+ uses: codecov/codecov-action@v7
+ with:
+ token: ${{ secrets.CODECOV_TOKEN }}
diff --git a/.github/workflows/composite/cartopy-cache/action.yml b/.github/workflows/composite/cartopy-cache/action.yml
new file mode 100644
index 00000000..e41f575a
--- /dev/null
+++ b/.github/workflows/composite/cartopy-cache/action.yml
@@ -0,0 +1,41 @@
+name: "cartopy-cache"
+description: "create and cache cartopy assets"
+
+#
+# Assumes the environment contains the following variables:
+# - CONDA
+#
+inputs:
+ cache_build:
+ description: "conda environment cache build number"
+ required: false
+ default: "0"
+ cache_period:
+ description: "conda environment cache timestamp"
+ required: true
+ env_name:
+ description: "environment name"
+ required: true
+
+runs:
+ using: "composite"
+ steps:
+ - uses: actions/cache@v3
+ id: cartopy-cache
+ with:
+ path: ~/.local/share/cartopy
+ key: ${{ runner.os }}-cartopy-${{ inputs.env_name }}-p${{ inputs.cache_period }}-b${{ inputs.cache_build }}
+
+ - if: steps.cartopy-cache.outputs.cache-hit != 'true'
+ env:
+ CARTOPY_SHARE_DIR: ~/.local/share/cartopy
+ CARTOPY_FEATURE: https://raw.githubusercontent.com/SciTools/cartopy/v0.20.0/tools/cartopy_feature_download.py
+ shell: bash
+ run: |
+ # Require to explicitly activate the environment within the composite action.
+ source ${{ env.CONDA }}/etc/profile.d/conda.sh >/dev/null 2>&1
+ conda activate ${{ inputs.env_name }}
+ wget --quiet ${CARTOPY_FEATURE}
+ mkdir -p ${CARTOPY_SHARE_DIR}
+ # Requires a pre-installed version of cartopy within the environment.
+ python cartopy_feature_download.py physical --output ${CARTOPY_SHARE_DIR} --no-warn
\ No newline at end of file
diff --git a/.github/workflows/composite/conda-env-cache/action.yml b/.github/workflows/composite/conda-env-cache/action.yml
new file mode 100644
index 00000000..7a32a792
--- /dev/null
+++ b/.github/workflows/composite/conda-env-cache/action.yml
@@ -0,0 +1,35 @@
+name: "conda-env-cache"
+description: "create and cache the conda environment"
+
+#
+# Assumes the environment contains the following variables:
+# - CONDA
+#
+inputs:
+ cache_build:
+ description: "conda environment cache build number"
+ required: false
+ default: "0"
+ cache_period:
+ description: "conda environment cache timestamp"
+ required: true
+ env_name:
+ description: "environment name"
+ required: true
+ install_packages:
+ description: "conda packages to install into environment"
+ required: true
+
+runs:
+ using: "composite"
+ steps:
+ - uses: actions/cache@v3
+ id: conda-env-cache
+ with:
+ path: ${{ env.CONDA }}/envs/${{ inputs.env_name }}
+ key: ${{ runner.os }}-conda-env-${{ inputs.env_name }}-p${{ inputs.cache_period }}-b${{ inputs.cache_build }}
+
+ - if: steps.conda-env-cache.outputs.cache-hit != 'true'
+ shell: bash
+ run: |
+ conda install --quiet --name ${{ inputs.env_name }} ${{ inputs.install_packages }}
\ No newline at end of file
diff --git a/.github/workflows/composite/conda-pkg-cache/action.yml b/.github/workflows/composite/conda-pkg-cache/action.yml
new file mode 100644
index 00000000..d06c0941
--- /dev/null
+++ b/.github/workflows/composite/conda-pkg-cache/action.yml
@@ -0,0 +1,22 @@
+name: "conda-pkg-cache"
+description: "cache the conda environment packages"
+
+inputs:
+ cache_build:
+ description: "conda environment cache build number"
+ required: false
+ default: "0"
+ cache_period:
+ description: "conda environment cache timestamp"
+ required: true
+ env_name:
+ description: "environment name"
+ required: true
+
+runs:
+ using: "composite"
+ steps:
+ - uses: actions/cache@v3
+ with:
+ path: ~/conda_pkgs_dir
+ key: ${{ runner.os }}-conda-pkgs-${{ inputs.env_name }}-p${{ inputs.cache_period }}-b${{ inputs.cache_build }}
\ No newline at end of file
diff --git a/.github/workflows/composite/iris-data-cache/action.yml b/.github/workflows/composite/iris-data-cache/action.yml
new file mode 100644
index 00000000..5869ab64
--- /dev/null
+++ b/.github/workflows/composite/iris-data-cache/action.yml
@@ -0,0 +1,30 @@
+name: "iris-data-cache"
+description: "create and cache the iris test data"
+
+inputs:
+ cache_build:
+ description: "data cache build number"
+ required: false
+ default: "0"
+ env_name:
+ description: "environment name"
+ required: true
+ version:
+ description: "iris test data version"
+ required: true
+
+runs:
+ using: "composite"
+ steps:
+ - uses: actions/cache@v3
+ id: data-cache
+ with:
+ path: ~/iris-test-data
+ key: ${{ runner.os }}-iris-test-data-${{ inputs.env_name }}-v${{ inputs.version }}-b${{ inputs.cache_build }}
+
+ - if: steps.data-cache.outputs.cache-hit != 'true'
+ shell: bash
+ run: |
+ wget --quiet https://github.com/SciTools/iris-test-data/archive/v${{ inputs.version }}.zip -O iris-test-data.zip
+ unzip -q iris-test-data.zip
+ mv iris-test-data-${{ inputs.version }} ~/iris-test-data
\ No newline at end of file
diff --git a/.github/workflows/composite/nox-cache/action.yml b/.github/workflows/composite/nox-cache/action.yml
new file mode 100644
index 00000000..23447f84
--- /dev/null
+++ b/.github/workflows/composite/nox-cache/action.yml
@@ -0,0 +1,22 @@
+name: "nox cache"
+description: "cache the nox test environments"
+
+inputs:
+ cache_build:
+ description: "nox cache build number"
+ required: false
+ default: "0"
+ env_name:
+ description: "environment name"
+ required: true
+ lock_file:
+ description: "conda-lock environment requirements filename"
+ required: true
+
+runs:
+ using: "composite"
+ steps:
+ - uses: actions/cache@v3
+ with:
+ path: ${{ github.workspace }}/.nox
+ key: ${{ runner.os }}-nox-${{ inputs.env_name }}-py${{ matrix.python-version }}-b${{ inputs.cache_build }}-${{ hashFiles(inputs.lock_file) }}
\ No newline at end of file
diff --git a/.github/workflows/refresh-lockfiles.yml b/.github/workflows/refresh-lockfiles.yml
new file mode 100644
index 00000000..86674901
--- /dev/null
+++ b/.github/workflows/refresh-lockfiles.yml
@@ -0,0 +1,18 @@
+# Updates the environment lock files. See the called workflow in the
+# scitools/reusable_workflows repo for more details.
+name: Refresh Lockfiles
+
+
+on:
+ workflow_dispatch:
+ schedule:
+ - cron: "2 0 * * 6"
+
+permissions: {}
+
+jobs:
+ refresh_lockfiles:
+ uses: scitools/workflows/.github/workflows/refresh-lockfiles.yml@1f2141422a63321a32575ddd186e53acff12550c
+ secrets:
+ AUTH_APP_ID: ${{ secrets.AUTH_APP_ID }}
+ AUTH_APP_PRIVATE_KEY: ${{ secrets.AUTH_APP_PRIVATE_KEY }}
diff --git a/.gitignore b/.gitignore
index fcae05cd..f12351f4 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,26 +1,172 @@
-*.py[co]
+# VCS by setuptools-scm
+_version.py
-# Packages
-*.egg
-*.egg-info
-dist
-build
-eggs
-parts
-bin
-var
-sdist
-develop-eggs
+# Created by editors
+*~
+\#*
+\.\#*
+*.swp
+.idea/
+.vscode/
+
+# Byte-compiled / optimized / DLL files
+__pycache__/
+*.py[cod]
+*$py.class
+
+# C extensions
+*.so
+
+# Distribution / packaging
+.Python
+build/
+develop-eggs/
+dist/
+downloads/
+eggs/
+.eggs/
+lib/
+lib64/
+parts/
+sdist/
+var/
+wheels/
+share/python-wheels/
+*.egg-info/
.installed.cfg
+*.egg
+MANIFEST
+
+# PyInstaller
+# Usually these files are written by a python script from a template
+# before PyInstaller builds the exe, so as to inject date/other infos into it.
+*.manifest
+*.spec
# Installer logs
pip-log.txt
+pip-delete-this-directory.txt
-#shared objects
-*.so
+# Unit test / coverage reports
+htmlcov/
+.tox/
+.nox/
+.coverage
+.coverage.*
+.cache
+nosetests.xml
+coverage.xml
+*.cover
+*.py,cover
+.hypothesis/
+.pytest_cache/
+cover/
-# Created by editors
-*~
-\#*
-\.\#*
-*.swp
+# Translations
+*.mo
+*.pot
+
+# Django stuff:
+*.log
+local_settings.py
+db.sqlite3
+db.sqlite3-journal
+
+# Flask stuff:
+instance/
+.webassets-cache
+
+# Scrapy stuff:
+.scrapy
+
+# Sphinx documentation
+docs/_build/
+docs/api/
+
+# PyBuilder
+.pybuilder/
+target/
+
+# Jupyter Notebook
+.ipynb_checkpoints
+
+# IPython
+profile_default/
+ipython_config.py
+
+# pyenv
+# For a library or package, you might want to ignore these files since the code is
+# intended to run in multiple environments; otherwise, check them in:
+# .python-version
+
+# pipenv
+# According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control.
+# However, in case of collaboration, if having platform-specific dependencies or dependencies
+# having no cross-platform support, pipenv may install dependencies that don't work, or not
+# install all needed dependencies.
+#Pipfile.lock
+
+# poetry
+# Similar to Pipfile.lock, it is generally recommended to include poetry.lock in version control.
+# This is especially recommended for binary packages to ensure reproducibility, and is more
+# commonly ignored for libraries.
+# https://python-poetry.org/docs/basic-usage/#commit-your-poetrylock-file-to-version-control
+#poetry.lock
+
+# pdm
+# Similar to Pipfile.lock, it is generally recommended to include pdm.lock in version control.
+#pdm.lock
+# pdm stores project-wide configurations in .pdm.toml, but it is recommended to not include it
+# in version control.
+# https://pdm.fming.dev/#use-with-ide
+.pdm.toml
+
+# PEP 582; used by e.g. github.com/David-OConnor/pyflow and github.com/pdm-project/pdm
+__pypackages__/
+
+# Celery stuff
+celerybeat-schedule
+celerybeat.pid
+
+# SageMath parsed files
+*.sage.py
+
+# Environments
+.env
+.venv
+env/
+venv/
+ENV/
+env.bak/
+venv.bak/
+
+# Spyder project settings
+.spyderproject
+.spyproject
+
+# Rope project settings
+.ropeproject
+
+# mkdocs documentation
+/site
+
+# mypy
+.mypy_cache/
+.dmypy.json
+dmypy.json
+
+# Pyre type checker
+.pyre/
+
+# pytype static type analyzer
+.pytype/
+
+# Cython debug symbols
+cython_debug/
+
+# PyCharm
+# JetBrains specific template is maintained in a separate JetBrains.gitignore that can
+# be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore
+# and can be added to the global gitignore or merged into this file. For a more nuclear
+# option (not recommended) you can uncomment the following to ignore the entire idea folder.
+.idea/
diff --git a/.lycheeignore b/.lycheeignore
new file mode 100644
index 00000000..eb3c2bb1
--- /dev/null
+++ b/.lycheeignore
@@ -0,0 +1,10 @@
+# Change-log entries reference GitHub user accounts, which are common enough
+# to trigger GitHub rate limiting.
+https://github.com/[^/]*$
+
+# GitHub seems especially keen to rate-limit "blob" URLs.
+# (maybe because these are especially associated with abuse?)
+https://github.com/[^/]*/[^/]*/blob/.*
+
+# Returns 403 when accessed from GitHub Actions
+https://stackoverflow.com
\ No newline at end of file
diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml
new file mode 100644
index 00000000..13970687
--- /dev/null
+++ b/.pre-commit-config.yaml
@@ -0,0 +1,133 @@
+# See https://pre-commit.com for more information
+# See https://pre-commit.com/hooks.html for more hooks
+# See https://pre-commit.ci/#configuration
+# See https://github.com/scientific-python/cookie#sp-repo-review
+
+ci:
+ autofix_prs: true
+ autofix_commit_msg: "style: pre-commit fixes"
+ autoupdate_commit_msg: "chore: update pre-commit hooks"
+ autoupdate_schedule: "monthly"
+
+
+# Alphabetised, for lack of a better order.
+files: |
+ (?x)(
+ benchmarks\/.+\.py|
+ docs\/.+\.py|
+ docs\/.+\.rst|
+ lib\/.+\.py|
+ noxfile\.py|
+ pyproject\.toml|
+ setup\.py|
+ src\/.+\.py
+ )
+minimum_pre_commit_version: 1.21.0
+
+repos:
+- repo: https://github.com/pre-commit/pre-commit-hooks
+ rev: v6.0.0
+ hooks:
+ # Prevent giant files from being committed.
+ - id: check-added-large-files
+ # Check whether files parse as valid Python.
+ - id: check-ast
+ # Check for file name conflicts on case-insensitive filesystems.
+ - id: check-case-conflict
+ # Check for files that contain merge conflict strings.
+ - id: check-merge-conflict
+ # Check for debugger imports and py37+ `breakpoint()` calls in Python source.
+ - id: debug-statements
+ # Check TOML file syntax.
+ - id: check-toml
+ # Check YAML file syntax.
+ - id: check-yaml
+ # Makes sure files end in a newline and only a newline.
+ # Duplicates Ruff W292 but also works on non-Python files.
+ - id: end-of-file-fixer
+ # Replaces or checks mixed line ending.
+ - id: mixed-line-ending
+ # Don't commit to main branch.
+ - id: no-commit-to-branch
+ # Trims trailing whitespace.
+ # Duplicates Ruff W291 but also works on non-Python files.
+ - id: trailing-whitespace
+
+- repo: https://github.com/adamchainz/blacken-docs
+ rev: 1.20.0
+ hooks:
+ - id: blacken-docs
+ types: [file, rst]
+
+- repo: https://github.com/codespell-project/codespell
+ rev: "v2.4.2"
+ hooks:
+ - id: codespell
+ types_or: [asciidoc, python, markdown, rst]
+ additional_dependencies: [tomli]
+
+- repo: https://github.com/pre-commit/mirrors-mypy
+ rev: 'v1.20.2'
+ hooks:
+ - id: mypy
+ exclude: 'noxfile\.py|docs/conf\.py'
+
+- repo: https://github.com/numpy/numpydoc
+ rev: v1.10.0
+ hooks:
+ - id: numpydoc-validation
+ exclude: "src/iris_grib/tests/|noxfile.py"
+ types: [file, python]
+
+- repo: https://github.com/astral-sh/ruff-pre-commit
+ rev: "v0.15.12"
+ hooks:
+ - id: ruff-check
+ types: [file, python]
+ args: [--fix, --show-fixes]
+ - id: ruff-format
+ types: [file, python]
+
+- repo: https://github.com/aio-libs/sort-all
+ rev: v1.3.0
+ hooks:
+ - id: sort-all
+ types: [file, python]
+
+- repo: https://github.com/scientific-python/cookie
+ rev: 2026.04.04
+ hooks:
+ - id: sp-repo-review
+ additional_dependencies: ["repo-review[cli]"]
+ args: ["--show=errskip"]
+
+- repo: https://github.com/abravalheri/validate-pyproject
+ # More exhaustive than Ruff RUF200.
+ rev: "v0.25"
+ hooks:
+ - id: validate-pyproject
+
+- repo: https://github.com/pre-commit/pygrep-hooks
+ rev: v1.10.0
+ hooks:
+ - id: python-check-blanket-noqa
+ # Enforce that all noqa annotations always occur with specific codes.
+ - id: python-check-blanket-type-ignore
+ # Enforce that "# type: ignore" annotations always occur with specific codes.
+ - id: python-check-mock-methods
+ # Prevent common mistakes of assert mck.not_called(), assert
+ # mck.called_once_with(...) and mck.assert_called.
+ - id: python-no-eval
+ # A quick check for the eval() built-in function
+ - id: python-no-log-warn
+ # A quick check for the deprecated .warn() method of python loggers
+ - id: python-use-type-annotations
+ # Enforce that python3.6+ type annotations are used instead of type comments
+ - id: rst-backticks
+ # Detect common mistake of using single backticks when writing rst.
+ - id: rst-directive-colons
+ # Detect mistake of rst directive not ending with double colon.
+ - id: rst-inline-touching-normal
+ # Detect mistake of inline code touching normal text in rst.
+ - id: text-unicode-replacement-char
+ # Forbid files which have a UTF-8 Unicode replacement character.
diff --git a/.readthedocs.yml b/.readthedocs.yml
new file mode 100644
index 00000000..af304cb2
--- /dev/null
+++ b/.readthedocs.yml
@@ -0,0 +1,31 @@
+version: 2
+
+build:
+ os: ubuntu-20.04
+ tools:
+ python: mambaforge-4.10
+ jobs:
+ post_checkout:
+ # The SciTools/iris-grib repository is shallow i.e., has a .git/shallow,
+ # therefore complete the repository with a full history in order
+ # to allow setuptools-scm to correctly auto-discover the version.
+ - git fetch --unshallow
+ - git fetch --all
+ # Need to stash the local changes that Read the Docs makes so that
+ # setuptools_scm can generate the correct Iris-grib version.
+ pre_install:
+ - git stash
+ post_install:
+ - git stash pop
+
+conda:
+ environment: requirements/readthedocs.yml
+
+sphinx:
+ configuration: docs/conf.py
+ fail_on_warning: false
+
+python:
+ install:
+ - method: pip
+ path: .
diff --git a/.travis.yml b/.travis.yml
deleted file mode 100644
index c4d68ad9..00000000
--- a/.travis.yml
+++ /dev/null
@@ -1,82 +0,0 @@
-language: python
-sudo: false
-env:
- - python=2.7
- iris=1.9
-
- - python=2.7
- iris_from_source=master
- grib_api=1.14.7
-
-# - python=3.4
-# iris=master
-# grib_api=1.14.7
-
-# - python=3.5
-# iris=master
-# grib_api=1.14.7
-
-
-install:
- # Fetch and install conda
- # -----------------------
- - export CONDA_BASE=http://repo.continuum.io/miniconda/Miniconda3
- - wget ${CONDA_BASE}-latest-Linux-x86_64.sh -O miniconda.sh;
- - bash miniconda.sh -b -p $HOME/miniconda
- - export PATH="$HOME/miniconda/bin:$PATH"
- - conda config --set show_channel_urls True
- - conda config --add channels conda-forge
-
- # Install iris-grib's dependencies
- # --------------------------------
- - |
- conda install --quiet --yes python=${python} pep8 pip nomkl \
- iris=${iris}* \
- python-ecmwf_grib=${grib_api}*
-
- # Fetch and install Iris from source
- # ----------------------------------
- - |
- if [ -n "$iris_from_source" ]; then
- conda remove --yes iris;
- wget https://github.com/scitools/iris/archive/${iris_from_source}.tar.gz -O iris.tar.gz;
- tar xzf iris.tar.gz && rm -rf iris.tar.gz && mv iris-${iris_from_source} iris_source;
- pip install ./iris_source --no-deps;
- rm -rf iris_source;
- fi
-
- # Download iris-test-data
- # --------------------------------
- - export IRIS_TEST_DATA_REF=https://github.com/SciTools/iris-test-data/archive/master.zip
- - export IRIS_TEST_DATA_LOCATION=$HOME/iris-test-data
- - mkdir $IRIS_TEST_DATA_LOCATION
- - wget -O $IRIS_TEST_DATA_LOCATION/iris-test-data.zip ${IRIS_TEST_DATA_REF}
- - unzip -q $IRIS_TEST_DATA_LOCATION/iris-test-data.zip -d $IRIS_TEST_DATA_LOCATION
-
- # Locate iris installation
- # ------------------------
- - export IRIS_DIR=$(python -c "import iris; import os.path; print os.path.dirname(iris.__file__)")
-
- # Poke site.cfg to reference iris-test-data
- - SITE_CFG=$IRIS_DIR/etc/site.cfg
- - echo "[Resources]" > $SITE_CFG
- - echo "test_data_dir = ${IRIS_TEST_DATA_LOCATION}/iris-test-data-master/test_data" >> $SITE_CFG
-
- # Install iris-grib itself
- # ------------------------
- - pip install . --no-deps
-
- # Install coveralls for test coverage
- # -----------------------------------
- - pip install coveralls
-
- # Summarise the environment
- # -------------------------
- - conda list
-
-script:
- # Ensure we can import iris_grib and that the tests pass
- # ------------------------------------------------------
- - coverage run setup.py test
-
-after_success: coveralls
diff --git a/CITATION.cff b/CITATION.cff
new file mode 100644
index 00000000..460a07f2
--- /dev/null
+++ b/CITATION.cff
@@ -0,0 +1,11 @@
+cff-version: 1.2.0
+message: "If iris-grib played an important role in your research then please add us to your reference list by using the references below."
+title: "iris-grib"
+authors:
+ - name: "iris-grib repository contributors"
+abstract: "GRIB (GRIdded Binary) interface for Iris."
+license: "BSD-3-Clause"
+license-url: "https://spdx.org/licenses/BSD-3-Clause.html"
+url: "http://www.scitools.org.uk/"
+repository-code: "https://github.com/SciTools/iris-grib"
+type: "software"
diff --git a/CODE_OF_CONDUCT.md b/CODE_OF_CONDUCT.md
new file mode 100644
index 00000000..a959e3ed
--- /dev/null
+++ b/CODE_OF_CONDUCT.md
@@ -0,0 +1,133 @@
+
+# Contributor Covenant Code of Conduct
+
+## Our Pledge
+
+We as members, contributors, and leaders pledge to make participation in our
+community a harassment-free experience for everyone, regardless of age, body
+size, visible or invisible disability, ethnicity, sex characteristics, gender
+identity and expression, level of experience, education, socio-economic status,
+nationality, personal appearance, race, caste, color, religion, or sexual
+identity and orientation.
+
+We pledge to act and interact in ways that contribute to an open, welcoming,
+diverse, inclusive, and healthy community.
+
+## Our Standards
+
+Examples of behavior that contributes to a positive environment for our
+community include:
+
+* Demonstrating empathy and kindness toward other people
+* Being respectful of differing opinions, viewpoints, and experiences
+* Giving and gracefully accepting constructive feedback
+* Accepting responsibility and apologizing to those affected by our mistakes,
+ and learning from the experience
+* Focusing on what is best not just for us as individuals, but for the overall
+ community
+
+Examples of unacceptable behavior include:
+
+* The use of sexualized language or imagery, and sexual attention or advances of
+ any kind
+* Trolling, insulting or derogatory comments, and personal or political attacks
+* Public or private harassment
+* Publishing others' private information, such as a physical or email address,
+ without their explicit permission
+* Other conduct which could reasonably be considered inappropriate in a
+ professional setting
+
+## Enforcement Responsibilities
+
+Community leaders are responsible for clarifying and enforcing our standards of
+acceptable behavior and will take appropriate and fair corrective action in
+response to any behavior that they deem inappropriate, threatening, offensive,
+or harmful.
+
+Community leaders have the right and responsibility to remove, edit, or reject
+comments, commits, code, wiki edits, issues, and other contributions that are
+not aligned to this Code of Conduct, and will communicate reasons for moderation
+decisions when appropriate.
+
+## Scope
+
+This Code of Conduct applies within all community spaces, and also applies when
+an individual is officially representing the community in public spaces.
+Examples of representing our community include using an official e-mail address,
+posting via an official social media account, or acting as an appointed
+representative at an online or offline event.
+
+## Enforcement
+
+Instances of abusive, harassing, or otherwise unacceptable behavior may be
+reported to the community leaders responsible for enforcement at
+geovista.pub@gmail.com.
+All complaints will be reviewed and investigated promptly and fairly.
+
+All community leaders are obligated to respect the privacy and security of the
+reporter of any incident.
+
+## Enforcement Guidelines
+
+Community leaders will follow these Community Impact Guidelines in determining
+the consequences for any action they deem in violation of this Code of Conduct:
+
+### 1. Correction
+
+**Community Impact**: Use of inappropriate language or other behavior deemed
+unprofessional or unwelcome in the community.
+
+**Consequence**: A private, written warning from community leaders, providing
+clarity around the nature of the violation and an explanation of why the
+behavior was inappropriate. A public apology may be requested.
+
+### 2. Warning
+
+**Community Impact**: A violation through a single incident or series of
+actions.
+
+**Consequence**: A warning with consequences for continued behavior. No
+interaction with the people involved, including unsolicited interaction with
+those enforcing the Code of Conduct, for a specified period of time. This
+includes avoiding interactions in community spaces as well as external channels
+like social media. Violating these terms may lead to a temporary or permanent
+ban.
+
+### 3. Temporary Ban
+
+**Community Impact**: A serious violation of community standards, including
+sustained inappropriate behavior.
+
+**Consequence**: A temporary ban from any sort of interaction or public
+communication with the community for a specified period of time. No public or
+private interaction with the people involved, including unsolicited interaction
+with those enforcing the Code of Conduct, is allowed during this period.
+Violating these terms may lead to a permanent ban.
+
+### 4. Permanent Ban
+
+**Community Impact**: Demonstrating a pattern of violation of community
+standards, including sustained inappropriate behavior, harassment of an
+individual, or aggression toward or disparagement of classes of individuals.
+
+**Consequence**: A permanent ban from any sort of public interaction within the
+community.
+
+## Attribution
+
+This Code of Conduct is adapted from the [Contributor Covenant][homepage],
+version 2.1, available at
+[https://www.contributor-covenant.org/version/2/1/code_of_conduct.html][v2.1].
+
+Community Impact Guidelines were inspired by
+[Mozilla's code of conduct enforcement ladder][Mozilla CoC].
+
+For answers to common questions about this code of conduct, see the FAQ at
+[https://www.contributor-covenant.org/faq][FAQ]. Translations are available at
+[https://www.contributor-covenant.org/translations][translations].
+
+[homepage]: https://www.contributor-covenant.org
+[v2.1]: https://www.contributor-covenant.org/version/2/1/code_of_conduct.html
+[Mozilla CoC]: https://github.com/mozilla/diversity
+[FAQ]: https://www.contributor-covenant.org/faq
+[translations]: https://www.contributor-covenant.org/translations
diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md
index 8952a210..a4ce74ad 100644
--- a/CONTRIBUTING.md
+++ b/CONTRIBUTING.md
@@ -12,9 +12,9 @@ Getting started
1. If you've not already got one, sign up for a
[GitHub account](https://github.com/signup/free).
2. Fork the iris-grib repository, create your new fix/feature branch, and
- start commiting code.
+ start committing code.
- The main
- [Iris development guide](http://scitools.org.uk/iris/docs/latest/developers_guide/gitwash/git_development.html)
+ [Iris development guide](https://scitools-iris.readthedocs.io/en/latest/developers_guide/gitwash/index.html)
has more detail.
3. Remember to add appropriate documentation and tests to supplement any new or changed functionality.
@@ -22,11 +22,11 @@ Getting started
Submitting changes
------------------
-1. Read and sign the Contributor Licence Agreement (CLA).
- - See our [governance page](http://scitools.org.uk/governance.html)
- for the CLA and what to do with it.
-2. Push your branch to your fork of iris-grib.
-3. Submit your pull request.
+1. Push your branch to your fork of iris-grib.
+2. Submit your pull request.
+3. Note that all authors on pull requests will automatically be asked to sign the
+ [SciTools Contributor Licence Agreement](https://cla-assistant.io/SciTools/)
+ (CLA), if they have not already done so.
4. Sit back and wait for the core iris-grib development team to review
your code.
diff --git a/COPYING b/COPYING
deleted file mode 100644
index 94a9ed02..00000000
--- a/COPYING
+++ /dev/null
@@ -1,674 +0,0 @@
- GNU GENERAL PUBLIC LICENSE
- Version 3, 29 June 2007
-
- Copyright (C) 2007 Free Software Foundation, Inc.
- Everyone is permitted to copy and distribute verbatim copies
- of this license document, but changing it is not allowed.
-
- Preamble
-
- The GNU General Public License is a free, copyleft license for
-software and other kinds of works.
-
- The licenses for most software and other practical works are designed
-to take away your freedom to share and change the works. By contrast,
-the GNU General Public License is intended to guarantee your freedom to
-share and change all versions of a program--to make sure it remains free
-software for all its users. We, the Free Software Foundation, use the
-GNU General Public License for most of our software; it applies also to
-any other work released this way by its authors. You can apply it to
-your programs, too.
-
- When we speak of free software, we are referring to freedom, not
-price. Our General Public Licenses are designed to make sure that you
-have the freedom to distribute copies of free software (and charge for
-them if you wish), that you receive source code or can get it if you
-want it, that you can change the software or use pieces of it in new
-free programs, and that you know you can do these things.
-
- To protect your rights, we need to prevent others from denying you
-these rights or asking you to surrender the rights. Therefore, you have
-certain responsibilities if you distribute copies of the software, or if
-you modify it: responsibilities to respect the freedom of others.
-
- For example, if you distribute copies of such a program, whether
-gratis or for a fee, you must pass on to the recipients the same
-freedoms that you received. You must make sure that they, too, receive
-or can get the source code. And you must show them these terms so they
-know their rights.
-
- Developers that use the GNU GPL protect your rights with two steps:
-(1) assert copyright on the software, and (2) offer you this License
-giving you legal permission to copy, distribute and/or modify it.
-
- For the developers' and authors' protection, the GPL clearly explains
-that there is no warranty for this free software. For both users' and
-authors' sake, the GPL requires that modified versions be marked as
-changed, so that their problems will not be attributed erroneously to
-authors of previous versions.
-
- Some devices are designed to deny users access to install or run
-modified versions of the software inside them, although the manufacturer
-can do so. This is fundamentally incompatible with the aim of
-protecting users' freedom to change the software. The systematic
-pattern of such abuse occurs in the area of products for individuals to
-use, which is precisely where it is most unacceptable. Therefore, we
-have designed this version of the GPL to prohibit the practice for those
-products. If such problems arise substantially in other domains, we
-stand ready to extend this provision to those domains in future versions
-of the GPL, as needed to protect the freedom of users.
-
- Finally, every program is threatened constantly by software patents.
-States should not allow patents to restrict development and use of
-software on general-purpose computers, but in those that do, we wish to
-avoid the special danger that patents applied to a free program could
-make it effectively proprietary. To prevent this, the GPL assures that
-patents cannot be used to render the program non-free.
-
- The precise terms and conditions for copying, distribution and
-modification follow.
-
- TERMS AND CONDITIONS
-
- 0. Definitions.
-
- "This License" refers to version 3 of the GNU General Public License.
-
- "Copyright" also means copyright-like laws that apply to other kinds of
-works, such as semiconductor masks.
-
- "The Program" refers to any copyrightable work licensed under this
-License. Each licensee is addressed as "you". "Licensees" and
-"recipients" may be individuals or organizations.
-
- To "modify" a work means to copy from or adapt all or part of the work
-in a fashion requiring copyright permission, other than the making of an
-exact copy. The resulting work is called a "modified version" of the
-earlier work or a work "based on" the earlier work.
-
- A "covered work" means either the unmodified Program or a work based
-on the Program.
-
- To "propagate" a work means to do anything with it that, without
-permission, would make you directly or secondarily liable for
-infringement under applicable copyright law, except executing it on a
-computer or modifying a private copy. Propagation includes copying,
-distribution (with or without modification), making available to the
-public, and in some countries other activities as well.
-
- To "convey" a work means any kind of propagation that enables other
-parties to make or receive copies. Mere interaction with a user through
-a computer network, with no transfer of a copy, is not conveying.
-
- An interactive user interface displays "Appropriate Legal Notices"
-to the extent that it includes a convenient and prominently visible
-feature that (1) displays an appropriate copyright notice, and (2)
-tells the user that there is no warranty for the work (except to the
-extent that warranties are provided), that licensees may convey the
-work under this License, and how to view a copy of this License. If
-the interface presents a list of user commands or options, such as a
-menu, a prominent item in the list meets this criterion.
-
- 1. Source Code.
-
- The "source code" for a work means the preferred form of the work
-for making modifications to it. "Object code" means any non-source
-form of a work.
-
- A "Standard Interface" means an interface that either is an official
-standard defined by a recognized standards body, or, in the case of
-interfaces specified for a particular programming language, one that
-is widely used among developers working in that language.
-
- The "System Libraries" of an executable work include anything, other
-than the work as a whole, that (a) is included in the normal form of
-packaging a Major Component, but which is not part of that Major
-Component, and (b) serves only to enable use of the work with that
-Major Component, or to implement a Standard Interface for which an
-implementation is available to the public in source code form. A
-"Major Component", in this context, means a major essential component
-(kernel, window system, and so on) of the specific operating system
-(if any) on which the executable work runs, or a compiler used to
-produce the work, or an object code interpreter used to run it.
-
- The "Corresponding Source" for a work in object code form means all
-the source code needed to generate, install, and (for an executable
-work) run the object code and to modify the work, including scripts to
-control those activities. However, it does not include the work's
-System Libraries, or general-purpose tools or generally available free
-programs which are used unmodified in performing those activities but
-which are not part of the work. For example, Corresponding Source
-includes interface definition files associated with source files for
-the work, and the source code for shared libraries and dynamically
-linked subprograms that the work is specifically designed to require,
-such as by intimate data communication or control flow between those
-subprograms and other parts of the work.
-
- The Corresponding Source need not include anything that users
-can regenerate automatically from other parts of the Corresponding
-Source.
-
- The Corresponding Source for a work in source code form is that
-same work.
-
- 2. Basic Permissions.
-
- All rights granted under this License are granted for the term of
-copyright on the Program, and are irrevocable provided the stated
-conditions are met. This License explicitly affirms your unlimited
-permission to run the unmodified Program. The output from running a
-covered work is covered by this License only if the output, given its
-content, constitutes a covered work. This License acknowledges your
-rights of fair use or other equivalent, as provided by copyright law.
-
- You may make, run and propagate covered works that you do not
-convey, without conditions so long as your license otherwise remains
-in force. You may convey covered works to others for the sole purpose
-of having them make modifications exclusively for you, or provide you
-with facilities for running those works, provided that you comply with
-the terms of this License in conveying all material for which you do
-not control copyright. Those thus making or running the covered works
-for you must do so exclusively on your behalf, under your direction
-and control, on terms that prohibit them from making any copies of
-your copyrighted material outside their relationship with you.
-
- Conveying under any other circumstances is permitted solely under
-the conditions stated below. Sublicensing is not allowed; section 10
-makes it unnecessary.
-
- 3. Protecting Users' Legal Rights From Anti-Circumvention Law.
-
- No covered work shall be deemed part of an effective technological
-measure under any applicable law fulfilling obligations under article
-11 of the WIPO copyright treaty adopted on 20 December 1996, or
-similar laws prohibiting or restricting circumvention of such
-measures.
-
- When you convey a covered work, you waive any legal power to forbid
-circumvention of technological measures to the extent such circumvention
-is effected by exercising rights under this License with respect to
-the covered work, and you disclaim any intention to limit operation or
-modification of the work as a means of enforcing, against the work's
-users, your or third parties' legal rights to forbid circumvention of
-technological measures.
-
- 4. Conveying Verbatim Copies.
-
- You may convey verbatim copies of the Program's source code as you
-receive it, in any medium, provided that you conspicuously and
-appropriately publish on each copy an appropriate copyright notice;
-keep intact all notices stating that this License and any
-non-permissive terms added in accord with section 7 apply to the code;
-keep intact all notices of the absence of any warranty; and give all
-recipients a copy of this License along with the Program.
-
- You may charge any price or no price for each copy that you convey,
-and you may offer support or warranty protection for a fee.
-
- 5. Conveying Modified Source Versions.
-
- You may convey a work based on the Program, or the modifications to
-produce it from the Program, in the form of source code under the
-terms of section 4, provided that you also meet all of these conditions:
-
- a) The work must carry prominent notices stating that you modified
- it, and giving a relevant date.
-
- b) The work must carry prominent notices stating that it is
- released under this License and any conditions added under section
- 7. This requirement modifies the requirement in section 4 to
- "keep intact all notices".
-
- c) You must license the entire work, as a whole, under this
- License to anyone who comes into possession of a copy. This
- License will therefore apply, along with any applicable section 7
- additional terms, to the whole of the work, and all its parts,
- regardless of how they are packaged. This License gives no
- permission to license the work in any other way, but it does not
- invalidate such permission if you have separately received it.
-
- d) If the work has interactive user interfaces, each must display
- Appropriate Legal Notices; however, if the Program has interactive
- interfaces that do not display Appropriate Legal Notices, your
- work need not make them do so.
-
- A compilation of a covered work with other separate and independent
-works, which are not by their nature extensions of the covered work,
-and which are not combined with it such as to form a larger program,
-in or on a volume of a storage or distribution medium, is called an
-"aggregate" if the compilation and its resulting copyright are not
-used to limit the access or legal rights of the compilation's users
-beyond what the individual works permit. Inclusion of a covered work
-in an aggregate does not cause this License to apply to the other
-parts of the aggregate.
-
- 6. Conveying Non-Source Forms.
-
- You may convey a covered work in object code form under the terms
-of sections 4 and 5, provided that you also convey the
-machine-readable Corresponding Source under the terms of this License,
-in one of these ways:
-
- a) Convey the object code in, or embodied in, a physical product
- (including a physical distribution medium), accompanied by the
- Corresponding Source fixed on a durable physical medium
- customarily used for software interchange.
-
- b) Convey the object code in, or embodied in, a physical product
- (including a physical distribution medium), accompanied by a
- written offer, valid for at least three years and valid for as
- long as you offer spare parts or customer support for that product
- model, to give anyone who possesses the object code either (1) a
- copy of the Corresponding Source for all the software in the
- product that is covered by this License, on a durable physical
- medium customarily used for software interchange, for a price no
- more than your reasonable cost of physically performing this
- conveying of source, or (2) access to copy the
- Corresponding Source from a network server at no charge.
-
- c) Convey individual copies of the object code with a copy of the
- written offer to provide the Corresponding Source. This
- alternative is allowed only occasionally and noncommercially, and
- only if you received the object code with such an offer, in accord
- with subsection 6b.
-
- d) Convey the object code by offering access from a designated
- place (gratis or for a charge), and offer equivalent access to the
- Corresponding Source in the same way through the same place at no
- further charge. You need not require recipients to copy the
- Corresponding Source along with the object code. If the place to
- copy the object code is a network server, the Corresponding Source
- may be on a different server (operated by you or a third party)
- that supports equivalent copying facilities, provided you maintain
- clear directions next to the object code saying where to find the
- Corresponding Source. Regardless of what server hosts the
- Corresponding Source, you remain obligated to ensure that it is
- available for as long as needed to satisfy these requirements.
-
- e) Convey the object code using peer-to-peer transmission, provided
- you inform other peers where the object code and Corresponding
- Source of the work are being offered to the general public at no
- charge under subsection 6d.
-
- A separable portion of the object code, whose source code is excluded
-from the Corresponding Source as a System Library, need not be
-included in conveying the object code work.
-
- A "User Product" is either (1) a "consumer product", which means any
-tangible personal property which is normally used for personal, family,
-or household purposes, or (2) anything designed or sold for incorporation
-into a dwelling. In determining whether a product is a consumer product,
-doubtful cases shall be resolved in favor of coverage. For a particular
-product received by a particular user, "normally used" refers to a
-typical or common use of that class of product, regardless of the status
-of the particular user or of the way in which the particular user
-actually uses, or expects or is expected to use, the product. A product
-is a consumer product regardless of whether the product has substantial
-commercial, industrial or non-consumer uses, unless such uses represent
-the only significant mode of use of the product.
-
- "Installation Information" for a User Product means any methods,
-procedures, authorization keys, or other information required to install
-and execute modified versions of a covered work in that User Product from
-a modified version of its Corresponding Source. The information must
-suffice to ensure that the continued functioning of the modified object
-code is in no case prevented or interfered with solely because
-modification has been made.
-
- If you convey an object code work under this section in, or with, or
-specifically for use in, a User Product, and the conveying occurs as
-part of a transaction in which the right of possession and use of the
-User Product is transferred to the recipient in perpetuity or for a
-fixed term (regardless of how the transaction is characterized), the
-Corresponding Source conveyed under this section must be accompanied
-by the Installation Information. But this requirement does not apply
-if neither you nor any third party retains the ability to install
-modified object code on the User Product (for example, the work has
-been installed in ROM).
-
- The requirement to provide Installation Information does not include a
-requirement to continue to provide support service, warranty, or updates
-for a work that has been modified or installed by the recipient, or for
-the User Product in which it has been modified or installed. Access to a
-network may be denied when the modification itself materially and
-adversely affects the operation of the network or violates the rules and
-protocols for communication across the network.
-
- Corresponding Source conveyed, and Installation Information provided,
-in accord with this section must be in a format that is publicly
-documented (and with an implementation available to the public in
-source code form), and must require no special password or key for
-unpacking, reading or copying.
-
- 7. Additional Terms.
-
- "Additional permissions" are terms that supplement the terms of this
-License by making exceptions from one or more of its conditions.
-Additional permissions that are applicable to the entire Program shall
-be treated as though they were included in this License, to the extent
-that they are valid under applicable law. If additional permissions
-apply only to part of the Program, that part may be used separately
-under those permissions, but the entire Program remains governed by
-this License without regard to the additional permissions.
-
- When you convey a copy of a covered work, you may at your option
-remove any additional permissions from that copy, or from any part of
-it. (Additional permissions may be written to require their own
-removal in certain cases when you modify the work.) You may place
-additional permissions on material, added by you to a covered work,
-for which you have or can give appropriate copyright permission.
-
- Notwithstanding any other provision of this License, for material you
-add to a covered work, you may (if authorized by the copyright holders of
-that material) supplement the terms of this License with terms:
-
- a) Disclaiming warranty or limiting liability differently from the
- terms of sections 15 and 16 of this License; or
-
- b) Requiring preservation of specified reasonable legal notices or
- author attributions in that material or in the Appropriate Legal
- Notices displayed by works containing it; or
-
- c) Prohibiting misrepresentation of the origin of that material, or
- requiring that modified versions of such material be marked in
- reasonable ways as different from the original version; or
-
- d) Limiting the use for publicity purposes of names of licensors or
- authors of the material; or
-
- e) Declining to grant rights under trademark law for use of some
- trade names, trademarks, or service marks; or
-
- f) Requiring indemnification of licensors and authors of that
- material by anyone who conveys the material (or modified versions of
- it) with contractual assumptions of liability to the recipient, for
- any liability that these contractual assumptions directly impose on
- those licensors and authors.
-
- All other non-permissive additional terms are considered "further
-restrictions" within the meaning of section 10. If the Program as you
-received it, or any part of it, contains a notice stating that it is
-governed by this License along with a term that is a further
-restriction, you may remove that term. If a license document contains
-a further restriction but permits relicensing or conveying under this
-License, you may add to a covered work material governed by the terms
-of that license document, provided that the further restriction does
-not survive such relicensing or conveying.
-
- If you add terms to a covered work in accord with this section, you
-must place, in the relevant source files, a statement of the
-additional terms that apply to those files, or a notice indicating
-where to find the applicable terms.
-
- Additional terms, permissive or non-permissive, may be stated in the
-form of a separately written license, or stated as exceptions;
-the above requirements apply either way.
-
- 8. Termination.
-
- You may not propagate or modify a covered work except as expressly
-provided under this License. Any attempt otherwise to propagate or
-modify it is void, and will automatically terminate your rights under
-this License (including any patent licenses granted under the third
-paragraph of section 11).
-
- However, if you cease all violation of this License, then your
-license from a particular copyright holder is reinstated (a)
-provisionally, unless and until the copyright holder explicitly and
-finally terminates your license, and (b) permanently, if the copyright
-holder fails to notify you of the violation by some reasonable means
-prior to 60 days after the cessation.
-
- Moreover, your license from a particular copyright holder is
-reinstated permanently if the copyright holder notifies you of the
-violation by some reasonable means, this is the first time you have
-received notice of violation of this License (for any work) from that
-copyright holder, and you cure the violation prior to 30 days after
-your receipt of the notice.
-
- Termination of your rights under this section does not terminate the
-licenses of parties who have received copies or rights from you under
-this License. If your rights have been terminated and not permanently
-reinstated, you do not qualify to receive new licenses for the same
-material under section 10.
-
- 9. Acceptance Not Required for Having Copies.
-
- You are not required to accept this License in order to receive or
-run a copy of the Program. Ancillary propagation of a covered work
-occurring solely as a consequence of using peer-to-peer transmission
-to receive a copy likewise does not require acceptance. However,
-nothing other than this License grants you permission to propagate or
-modify any covered work. These actions infringe copyright if you do
-not accept this License. Therefore, by modifying or propagating a
-covered work, you indicate your acceptance of this License to do so.
-
- 10. Automatic Licensing of Downstream Recipients.
-
- Each time you convey a covered work, the recipient automatically
-receives a license from the original licensors, to run, modify and
-propagate that work, subject to this License. You are not responsible
-for enforcing compliance by third parties with this License.
-
- An "entity transaction" is a transaction transferring control of an
-organization, or substantially all assets of one, or subdividing an
-organization, or merging organizations. If propagation of a covered
-work results from an entity transaction, each party to that
-transaction who receives a copy of the work also receives whatever
-licenses to the work the party's predecessor in interest had or could
-give under the previous paragraph, plus a right to possession of the
-Corresponding Source of the work from the predecessor in interest, if
-the predecessor has it or can get it with reasonable efforts.
-
- You may not impose any further restrictions on the exercise of the
-rights granted or affirmed under this License. For example, you may
-not impose a license fee, royalty, or other charge for exercise of
-rights granted under this License, and you may not initiate litigation
-(including a cross-claim or counterclaim in a lawsuit) alleging that
-any patent claim is infringed by making, using, selling, offering for
-sale, or importing the Program or any portion of it.
-
- 11. Patents.
-
- A "contributor" is a copyright holder who authorizes use under this
-License of the Program or a work on which the Program is based. The
-work thus licensed is called the contributor's "contributor version".
-
- A contributor's "essential patent claims" are all patent claims
-owned or controlled by the contributor, whether already acquired or
-hereafter acquired, that would be infringed by some manner, permitted
-by this License, of making, using, or selling its contributor version,
-but do not include claims that would be infringed only as a
-consequence of further modification of the contributor version. For
-purposes of this definition, "control" includes the right to grant
-patent sublicenses in a manner consistent with the requirements of
-this License.
-
- Each contributor grants you a non-exclusive, worldwide, royalty-free
-patent license under the contributor's essential patent claims, to
-make, use, sell, offer for sale, import and otherwise run, modify and
-propagate the contents of its contributor version.
-
- In the following three paragraphs, a "patent license" is any express
-agreement or commitment, however denominated, not to enforce a patent
-(such as an express permission to practice a patent or covenant not to
-sue for patent infringement). To "grant" such a patent license to a
-party means to make such an agreement or commitment not to enforce a
-patent against the party.
-
- If you convey a covered work, knowingly relying on a patent license,
-and the Corresponding Source of the work is not available for anyone
-to copy, free of charge and under the terms of this License, through a
-publicly available network server or other readily accessible means,
-then you must either (1) cause the Corresponding Source to be so
-available, or (2) arrange to deprive yourself of the benefit of the
-patent license for this particular work, or (3) arrange, in a manner
-consistent with the requirements of this License, to extend the patent
-license to downstream recipients. "Knowingly relying" means you have
-actual knowledge that, but for the patent license, your conveying the
-covered work in a country, or your recipient's use of the covered work
-in a country, would infringe one or more identifiable patents in that
-country that you have reason to believe are valid.
-
- If, pursuant to or in connection with a single transaction or
-arrangement, you convey, or propagate by procuring conveyance of, a
-covered work, and grant a patent license to some of the parties
-receiving the covered work authorizing them to use, propagate, modify
-or convey a specific copy of the covered work, then the patent license
-you grant is automatically extended to all recipients of the covered
-work and works based on it.
-
- A patent license is "discriminatory" if it does not include within
-the scope of its coverage, prohibits the exercise of, or is
-conditioned on the non-exercise of one or more of the rights that are
-specifically granted under this License. You may not convey a covered
-work if you are a party to an arrangement with a third party that is
-in the business of distributing software, under which you make payment
-to the third party based on the extent of your activity of conveying
-the work, and under which the third party grants, to any of the
-parties who would receive the covered work from you, a discriminatory
-patent license (a) in connection with copies of the covered work
-conveyed by you (or copies made from those copies), or (b) primarily
-for and in connection with specific products or compilations that
-contain the covered work, unless you entered into that arrangement,
-or that patent license was granted, prior to 28 March 2007.
-
- Nothing in this License shall be construed as excluding or limiting
-any implied license or other defenses to infringement that may
-otherwise be available to you under applicable patent law.
-
- 12. No Surrender of Others' Freedom.
-
- If conditions are imposed on you (whether by court order, agreement or
-otherwise) that contradict the conditions of this License, they do not
-excuse you from the conditions of this License. If you cannot convey a
-covered work so as to satisfy simultaneously your obligations under this
-License and any other pertinent obligations, then as a consequence you may
-not convey it at all. For example, if you agree to terms that obligate you
-to collect a royalty for further conveying from those to whom you convey
-the Program, the only way you could satisfy both those terms and this
-License would be to refrain entirely from conveying the Program.
-
- 13. Use with the GNU Affero General Public License.
-
- Notwithstanding any other provision of this License, you have
-permission to link or combine any covered work with a work licensed
-under version 3 of the GNU Affero General Public License into a single
-combined work, and to convey the resulting work. The terms of this
-License will continue to apply to the part which is the covered work,
-but the special requirements of the GNU Affero General Public License,
-section 13, concerning interaction through a network will apply to the
-combination as such.
-
- 14. Revised Versions of this License.
-
- The Free Software Foundation may publish revised and/or new versions of
-the GNU General Public License from time to time. Such new versions will
-be similar in spirit to the present version, but may differ in detail to
-address new problems or concerns.
-
- Each version is given a distinguishing version number. If the
-Program specifies that a certain numbered version of the GNU General
-Public License "or any later version" applies to it, you have the
-option of following the terms and conditions either of that numbered
-version or of any later version published by the Free Software
-Foundation. If the Program does not specify a version number of the
-GNU General Public License, you may choose any version ever published
-by the Free Software Foundation.
-
- If the Program specifies that a proxy can decide which future
-versions of the GNU General Public License can be used, that proxy's
-public statement of acceptance of a version permanently authorizes you
-to choose that version for the Program.
-
- Later license versions may give you additional or different
-permissions. However, no additional obligations are imposed on any
-author or copyright holder as a result of your choosing to follow a
-later version.
-
- 15. Disclaimer of Warranty.
-
- THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY
-APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT
-HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY
-OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO,
-THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
-PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM
-IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF
-ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
-
- 16. Limitation of Liability.
-
- IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
-WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS
-THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY
-GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE
-USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF
-DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD
-PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS),
-EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF
-SUCH DAMAGES.
-
- 17. Interpretation of Sections 15 and 16.
-
- If the disclaimer of warranty and limitation of liability provided
-above cannot be given local legal effect according to their terms,
-reviewing courts shall apply local law that most closely approximates
-an absolute waiver of all civil liability in connection with the
-Program, unless a warranty or assumption of liability accompanies a
-copy of the Program in return for a fee.
-
- END OF TERMS AND CONDITIONS
-
- How to Apply These Terms to Your New Programs
-
- If you develop a new program, and you want it to be of the greatest
-possible use to the public, the best way to achieve this is to make it
-free software which everyone can redistribute and change under these terms.
-
- To do so, attach the following notices to the program. It is safest
-to attach them to the start of each source file to most effectively
-state the exclusion of warranty; and each file should have at least
-the "copyright" line and a pointer to where the full notice is found.
-
-
- Copyright (C)
-
- This program is free software: you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation, either version 3 of the License, or
- (at your option) any later version.
-
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program. If not, see .
-
-Also add information on how to contact you by electronic and paper mail.
-
- If the program does terminal interaction, make it output a short
-notice like this when it starts in an interactive mode:
-
- Copyright (C)
- This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
- This is free software, and you are welcome to redistribute it
- under certain conditions; type `show c' for details.
-
-The hypothetical commands `show w' and `show c' should show the appropriate
-parts of the General Public License. Of course, your program's commands
-might be different; for a GUI interface, you would use an "about box".
-
- You should also get your employer (if you work as a programmer) or school,
-if any, to sign a "copyright disclaimer" for the program, if necessary.
-For more information on this, and how to apply and follow the GNU GPL, see
-.
-
- The GNU General Public License does not permit incorporating your program
-into proprietary programs. If your program is a subroutine library, you
-may consider it more useful to permit linking proprietary applications with
-the library. If this is what you want to do, use the GNU Lesser General
-Public License instead of this License. But first, please read
-.
diff --git a/COPYING.LESSER b/COPYING.LESSER
deleted file mode 100644
index 65c5ca88..00000000
--- a/COPYING.LESSER
+++ /dev/null
@@ -1,165 +0,0 @@
- GNU LESSER GENERAL PUBLIC LICENSE
- Version 3, 29 June 2007
-
- Copyright (C) 2007 Free Software Foundation, Inc.
- Everyone is permitted to copy and distribute verbatim copies
- of this license document, but changing it is not allowed.
-
-
- This version of the GNU Lesser General Public License incorporates
-the terms and conditions of version 3 of the GNU General Public
-License, supplemented by the additional permissions listed below.
-
- 0. Additional Definitions.
-
- As used herein, "this License" refers to version 3 of the GNU Lesser
-General Public License, and the "GNU GPL" refers to version 3 of the GNU
-General Public License.
-
- "The Library" refers to a covered work governed by this License,
-other than an Application or a Combined Work as defined below.
-
- An "Application" is any work that makes use of an interface provided
-by the Library, but which is not otherwise based on the Library.
-Defining a subclass of a class defined by the Library is deemed a mode
-of using an interface provided by the Library.
-
- A "Combined Work" is a work produced by combining or linking an
-Application with the Library. The particular version of the Library
-with which the Combined Work was made is also called the "Linked
-Version".
-
- The "Minimal Corresponding Source" for a Combined Work means the
-Corresponding Source for the Combined Work, excluding any source code
-for portions of the Combined Work that, considered in isolation, are
-based on the Application, and not on the Linked Version.
-
- The "Corresponding Application Code" for a Combined Work means the
-object code and/or source code for the Application, including any data
-and utility programs needed for reproducing the Combined Work from the
-Application, but excluding the System Libraries of the Combined Work.
-
- 1. Exception to Section 3 of the GNU GPL.
-
- You may convey a covered work under sections 3 and 4 of this License
-without being bound by section 3 of the GNU GPL.
-
- 2. Conveying Modified Versions.
-
- If you modify a copy of the Library, and, in your modifications, a
-facility refers to a function or data to be supplied by an Application
-that uses the facility (other than as an argument passed when the
-facility is invoked), then you may convey a copy of the modified
-version:
-
- a) under this License, provided that you make a good faith effort to
- ensure that, in the event an Application does not supply the
- function or data, the facility still operates, and performs
- whatever part of its purpose remains meaningful, or
-
- b) under the GNU GPL, with none of the additional permissions of
- this License applicable to that copy.
-
- 3. Object Code Incorporating Material from Library Header Files.
-
- The object code form of an Application may incorporate material from
-a header file that is part of the Library. You may convey such object
-code under terms of your choice, provided that, if the incorporated
-material is not limited to numerical parameters, data structure
-layouts and accessors, or small macros, inline functions and templates
-(ten or fewer lines in length), you do both of the following:
-
- a) Give prominent notice with each copy of the object code that the
- Library is used in it and that the Library and its use are
- covered by this License.
-
- b) Accompany the object code with a copy of the GNU GPL and this license
- document.
-
- 4. Combined Works.
-
- You may convey a Combined Work under terms of your choice that,
-taken together, effectively do not restrict modification of the
-portions of the Library contained in the Combined Work and reverse
-engineering for debugging such modifications, if you also do each of
-the following:
-
- a) Give prominent notice with each copy of the Combined Work that
- the Library is used in it and that the Library and its use are
- covered by this License.
-
- b) Accompany the Combined Work with a copy of the GNU GPL and this license
- document.
-
- c) For a Combined Work that displays copyright notices during
- execution, include the copyright notice for the Library among
- these notices, as well as a reference directing the user to the
- copies of the GNU GPL and this license document.
-
- d) Do one of the following:
-
- 0) Convey the Minimal Corresponding Source under the terms of this
- License, and the Corresponding Application Code in a form
- suitable for, and under terms that permit, the user to
- recombine or relink the Application with a modified version of
- the Linked Version to produce a modified Combined Work, in the
- manner specified by section 6 of the GNU GPL for conveying
- Corresponding Source.
-
- 1) Use a suitable shared library mechanism for linking with the
- Library. A suitable mechanism is one that (a) uses at run time
- a copy of the Library already present on the user's computer
- system, and (b) will operate properly with a modified version
- of the Library that is interface-compatible with the Linked
- Version.
-
- e) Provide Installation Information, but only if you would otherwise
- be required to provide such information under section 6 of the
- GNU GPL, and only to the extent that such information is
- necessary to install and execute a modified version of the
- Combined Work produced by recombining or relinking the
- Application with a modified version of the Linked Version. (If
- you use option 4d0, the Installation Information must accompany
- the Minimal Corresponding Source and Corresponding Application
- Code. If you use option 4d1, you must provide the Installation
- Information in the manner specified by section 6 of the GNU GPL
- for conveying Corresponding Source.)
-
- 5. Combined Libraries.
-
- You may place library facilities that are a work based on the
-Library side by side in a single library together with other library
-facilities that are not Applications and are not covered by this
-License, and convey such a combined library under terms of your
-choice, if you do both of the following:
-
- a) Accompany the combined library with a copy of the same work based
- on the Library, uncombined with any other library facilities,
- conveyed under the terms of this License.
-
- b) Give prominent notice with the combined library that part of it
- is a work based on the Library, and explaining where to find the
- accompanying uncombined form of the same work.
-
- 6. Revised Versions of the GNU Lesser General Public License.
-
- The Free Software Foundation may publish revised and/or new versions
-of the GNU Lesser General Public License from time to time. Such new
-versions will be similar in spirit to the present version, but may
-differ in detail to address new problems or concerns.
-
- Each version is given a distinguishing version number. If the
-Library as you received it specifies that a certain numbered version
-of the GNU Lesser General Public License "or any later version"
-applies to it, you have the option of following the terms and
-conditions either of that published version or of any later version
-published by the Free Software Foundation. If the Library as you
-received it does not specify a version number of the GNU Lesser
-General Public License, you may choose any version of the GNU Lesser
-General Public License ever published by the Free Software Foundation.
-
- If the Library as you received it specifies that a proxy can decide
-whether future versions of the GNU Lesser General Public License shall
-apply, that proxy's public statement of acceptance of any version is
-permanent authorization for you to choose that version for the
-Library.
diff --git a/LICENSE b/LICENSE
new file mode 100644
index 00000000..2d1d23e1
--- /dev/null
+++ b/LICENSE
@@ -0,0 +1,29 @@
+BSD 3-Clause License
+
+Copyright (c) 2010, Met Office.
+All rights reserved.
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are met:
+
+1. Redistributions of source code must retain the above copyright notice, this
+ list of conditions and the following disclaimer.
+
+2. Redistributions in binary form must reproduce the above copyright notice,
+ this list of conditions and the following disclaimer in the documentation
+ and/or other materials provided with the distribution.
+
+3. Neither the name of the copyright holder nor the names of its
+ contributors may be used to endorse or promote products derived from
+ this software without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
+FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
+SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
+CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
+OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
diff --git a/MANIFEST.in b/MANIFEST.in
new file mode 100644
index 00000000..a9af457b
--- /dev/null
+++ b/MANIFEST.in
@@ -0,0 +1,92 @@
+# NOTE: based on a generic template in Scitools/.github/templates/MANIFEST.in
+
+# General principles
+# - enable user to build locally, as well as in CI
+# - make it ignore temporary files generated by dev processes, e.g. coverage checks
+# - encode typical decisions, e.g. whether we package docs, requirements etc
+
+#---------
+# SECTION: main code sources
+#
+recursive-include src *.cml *.grib2 *.json *.nc *.py
+ # principles:
+ # - *no* "prune" command is used
+ # - use "include-recursive", by relevant file extensions
+ # hints:
+ # - top-level dir is typically "src", but maybe "lib" or
+ # - default package rules mean we generally don't actually *need* a statement
+ # - but it's better to be explicit
+ # - extension filetypes are typically sources (*.py)
+ # - might also need testdata files, e.g. *.nc, *.npy *.npz
+ # - also possibly non-python, e.g. *.pyx for Cython
+
+
+#---------
+# SECTION: requirements
+prune requirements
+recursive-include requirements *.txt
+ # principles:
+ # include just requirements-level info, not lock files
+ # hints:
+ # - not all projects include requirements, but they can be drawn in anyway by dynamic dependencies
+ # in the setuptools build process, linked via config in pyproject.toml
+
+
+#---------
+# SECTION: root files
+exclude .flake8
+exclude .git-blame-ignore-revs
+exclude .git_archival.txt
+exclude .gitattributes
+exclude .gitignore
+exclude .lycheeignore
+exclude .mailmap
+exclude .pre-commit-config.yaml
+exclude .readthedocs.yml
+exclude .ruff.toml
+exclude CHANGES
+include CHANGELOG.md
+include CITATION.cff
+exclude CODE_OF_CONDUCT.md
+exclude CONTRIBUTING.md
+include COPYING
+include COPYING.LESSER
+include INSTALL
+include LICENSE
+exclude Makefile
+exclude codecov.yml
+include noxfile.py
+include tox.ini
+exclude pixi.lock
+ # principles:
+ # - *ANY* file in the root should be explicitly "include"- or "exclude"-d
+ # - EXCEPT (possibly) those covered by setuptools default rules (see above link)
+ # - including : README.md/.rst; pyproject.toml; setup.py/.cfg
+ # - N.B. a GHA "ci-manifest" check, if used, will check all this
+ # - the above are typical ones : given in sorted order
+ # - NB many will (eventually) be templated, but that is a separate issue
+ # - probably, this section can be included as *boilerplate*
+ # - i.e. it doesn't matter if some of the files mentioned don't exist
+
+
+#---------
+# SECTION: generic exclusions
+# (1) top-level directories to omit entirely
+prune .github
+prune .nox
+prune .tox
+prune .coverage
+prune docs
+# (2) top-level files to omit
+exclude .coveragerc
+# (3) file types (path patterns) to skip everywhere
+global-exclude *.py[cod]
+global-exclude __pycache__
+ # principles:
+ # - common directories, files and file-types to be generally ignored
+ # - all outside version control, temporary non-coding output and cache data
+ # produced by dev processes, automation or user tools
+ # - by having this section LAST, it can remove files which might have been added by
+ # previous sections -- such as python compiler cache files
+ # - can include this section as **boilerplate** :
+ # - won't all exist in every repo, but including them all does no harm
diff --git a/README.md b/README.md
new file mode 100644
index 00000000..baddfa6d
--- /dev/null
+++ b/README.md
@@ -0,0 +1,48 @@
+
+
+**Graphics and Lead Scientist**: [Ed Hawkins](https://www.met.reading.ac.uk/~ed/home/index.php), National Centre for Atmospheric Science, University of Reading.
+
+**Data**: Berkeley Earth, NOAA, UK Met Office, MeteoSwiss, DWD, SMHI, UoR, Meteo France & ZAMG.
+
+
+
diff --git a/README.rst b/README.rst
deleted file mode 100644
index ff31cc6b..00000000
--- a/README.rst
+++ /dev/null
@@ -1,39 +0,0 @@
-iris-grib
-=========
-
-|Travis|_ |Coveralls|_
-
-GRIB interface for `Iris `_.
-
-Code
-----
-iris-grib is licenced under the GNU Lesser General Public License (LGPLv3).
-
-The full text of the licence can be found in the COPYING and COPYING.LESSER
-files.
-
-Copyright and licence
----------------------
-
-\(C) British Crown Copyright 2010 - 2016, Met Office
-
-This file is part of iris-grib.
-
-iris-grib is free software: you can redistribute it and/or modify it under
-the terms of the GNU Lesser General Public License as published by the
-Free Software Foundation, either version 3 of the License, or
-(at your option) any later version.
-
-iris-grib is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU Lesser General Public License for more details.
-
-You should have received a copy of the GNU Lesser General Public License
-along with iris-grib. If not, see ``_.
-
-.. |Travis| image:: https://travis-ci.org/SciTools/iris-grib.svg?branch=master
-.. _Travis: https://travis-ci.org/SciTools/iris-grib
-
-.. |Coveralls| image:: https://coveralls.io/repos/github/SciTools/iris-grib/badge.svg?branch=master
-.. _Coveralls: https://coveralls.io/github/SciTools/iris-grib?branch=master
diff --git a/codecov.yml b/codecov.yml
new file mode 100644
index 00000000..b41476dc
--- /dev/null
+++ b/codecov.yml
@@ -0,0 +1,8 @@
+coverage:
+ # see https://docs.codecov.com/docs/commit-status
+ status:
+ project:
+ default:
+ target: auto
+ threshold: 5% # coverage can drop by up to % while still posting success
+ patch: off
diff --git a/docs/Makefile b/docs/Makefile
index 6e35eea2..3f197d11 100644
--- a/docs/Makefile
+++ b/docs/Makefile
@@ -19,6 +19,9 @@ ALLSPHINXOPTS = -d $(BUILDDIR)/doctrees $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) .
# the i18n builder cannot share the environment and doctrees with the others
I18NSPHINXOPTS = $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) .
+# See https://www.sphinx-doc.org/en/master/man/sphinx-build.html?highlight=--keep-going#cmdoption-sphinx-build-W
+WARNING_TO_ERROR = -W --keep-going
+
.PHONY: help
help:
@echo "Please use \`make ' where is one of"
@@ -44,7 +47,6 @@ help:
@echo " changes to make an overview of all changed/added/deprecated items"
@echo " xml to make Docutils-native XML files"
@echo " pseudoxml to make pseudoxml-XML files for display purposes"
- @echo " linkcheck to check all external links for integrity"
@echo " doctest to run all doctests embedded in the documentation (if enabled)"
@echo " coverage to run coverage check of the documentation (if enabled)"
@echo " dummy to check syntax errors of document sources"
@@ -52,10 +54,11 @@ help:
.PHONY: clean
clean:
rm -rf $(BUILDDIR)/*
+ rm -rf ./api
.PHONY: html
html:
- $(SPHINXBUILD) -b html $(ALLSPHINXOPTS) $(BUILDDIR)/html
+ $(SPHINXBUILD) $(WARNING_TO_ERROR) -b html $(ALLSPHINXOPTS) $(BUILDDIR)/html
@echo
@echo "Build finished. The HTML pages are in $(BUILDDIR)/html."
@@ -192,13 +195,6 @@ changes:
@echo
@echo "The overview file is in $(BUILDDIR)/changes."
-.PHONY: linkcheck
-linkcheck:
- $(SPHINXBUILD) -b linkcheck $(ALLSPHINXOPTS) $(BUILDDIR)/linkcheck
- @echo
- @echo "Link check complete; look for any errors in the above output " \
- "or in $(BUILDDIR)/linkcheck/output.txt."
-
.PHONY: doctest
doctest:
$(SPHINXBUILD) -b doctest $(ALLSPHINXOPTS) $(BUILDDIR)/doctest
diff --git a/docs/_static/iris-logo-title-dark.svg b/docs/_static/iris-logo-title-dark.svg
new file mode 100644
index 00000000..44d8a3bb
--- /dev/null
+++ b/docs/_static/iris-logo-title-dark.svg
@@ -0,0 +1,108 @@
+
+
\ No newline at end of file
diff --git a/docs/_static/iris-logo-title.svg b/docs/_static/iris-logo-title.svg
new file mode 100644
index 00000000..f1e7e236
--- /dev/null
+++ b/docs/_static/iris-logo-title.svg
@@ -0,0 +1,108 @@
+
+
+
+ Banner logo for the SciTools Iris project - https://github.com/SciTools/iris/
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Iris
+ GRIB
+
\ No newline at end of file
diff --git a/docs/conf.py b/docs/conf.py
index 799300d3..e6f26ae8 100644
--- a/docs/conf.py
+++ b/docs/conf.py
@@ -12,258 +12,250 @@
# All configuration values have a default; values that are commented out
# serve to show the default.
-import sys
-import os
+from importlib.metadata import version as get_version
+from pathlib import Path
-# If extensions (or modules to document with autodoc) are in another directory,
-# add these directories to sys.path here. If the directory is relative to the
-# documentation root, use os.path.abspath to make it absolute, like shown here.
-#sys.path.insert(0, os.path.abspath('.'))
# -- General configuration ------------------------------------------------
# If your documentation needs a minimal Sphinx version, state it here.
-#needs_sphinx = '1.0'
+# needs_sphinx = '1.0'
# Add any Sphinx extension module names here, as strings. They can be
# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
# ones.
extensions = [
- 'sphinx.ext.autodoc',
- 'sphinx.ext.doctest',
- 'sphinx.ext.intersphinx',
+ "sphinx.ext.apidoc", # included AS WELL AS autodoc : adds api in main build
+ "sphinx.ext.autodoc",
+ "sphinx.ext.doctest",
+ "sphinx.ext.intersphinx",
]
# Add any paths that contain templates here, relative to this directory.
-templates_path = ['_templates']
+templates_path = ["_templates"]
# The suffix(es) of source filenames.
# You can specify multiple suffix as a list of string:
# source_suffix = ['.rst', '.md']
-source_suffix = '.rst'
+source_suffix = {".rst": "restructuredtext"}
# The encoding of source files.
-#source_encoding = 'utf-8-sig'
+# source_encoding = 'utf-8-sig'
# The master toctree document.
-master_doc = 'index'
+master_doc = "index"
# General information about the project.
-project = u'iris-grib'
-copyright = u'2016, Met Office'
-author = u'Met Office'
+project = "iris-grib"
+copyright = "2022, Met Office"
+author = "Met Office"
# The version info for the project you're documenting, acts as replacement for
# |version| and |release|, also used in various other places throughout the
# built documents.
#
-# The short X.Y version.
-version = u'0.9'
-# The full version, including alpha/beta/rc tags.
-release = u'0.9.0'
+release = get_version("iris-grib")
# The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages.
#
# This is also used if you do content translation via gettext catalogs.
# Usually you set "language" from the command line for these cases.
-language = None
+# language = "en"
# There are two options for replacing |today|: either, you set today to some
# non-false value, then it is used:
-#today = ''
+# today = ''
# Else, today_fmt is used as the format for a strftime call.
-#today_fmt = '%B %d, %Y'
+# today_fmt = '%B %d, %Y'
# List of patterns, relative to source directory, that match files and
# directories to ignore when looking for source files.
# This patterns also effect to html_static_path and html_extra_path
-exclude_patterns = ['_build', 'Thumbs.db', '.DS_Store']
+exclude_patterns = ["_build", "Thumbs.db", ".DS_Store"]
# The reST default role (used for this markup: `text`) to use for all
# documents.
-#default_role = None
+# default_role = None
# If true, '()' will be appended to :func: etc. cross-reference text.
-#add_function_parentheses = True
+# add_function_parentheses = True
# If true, the current module name will be prepended to all description
# unit titles (such as .. function::).
-#add_module_names = True
+# add_module_names = True
# If true, sectionauthor and moduleauthor directives will be shown in the
# output. They are ignored by default.
-#show_authors = False
+# show_authors = False
# The name of the Pygments (syntax highlighting) style to use.
-pygments_style = 'sphinx'
+pygments_style = "sphinx"
# A list of ignored prefixes for module index sorting.
-#modindex_common_prefix = []
+# modindex_common_prefix = []
# If true, keep warnings as "system message" paragraphs in the built documents.
-#keep_warnings = False
+# keep_warnings = False
# If true, `todo` and `todoList` produce output, else they produce nothing.
todo_include_todos = False
+# -- Autodoc ------------------------------------------------------------------
+
+autodoc_member_order = "groupwise"
+autodoc_default_flags = ["show-inheritance"]
+
# -- Options for HTML output ----------------------------------------------
# The theme to use for HTML and HTML Help pages. See the documentation for
# a list of builtin themes.
-html_theme = 'sphinx_rtd_theme'
+html_theme = "sphinx_rtd_theme"
# Theme options are theme-specific and customize the look and feel of a theme
# further. For a list of options available for each theme, see the
# documentation.
-#html_theme_options = {}
+# html_theme_options = {}
# Add any paths that contain custom themes here, relative to this directory.
-#html_theme_path = []
+# html_theme_path = []
# The name for this set of Sphinx documents.
# " v documentation" by default.
-#html_title = u'iris-grib v0.1.0.dev0'
+# html_title = u'iris-grib v0.1.0.dev0'
# A shorter title for the navigation bar. Default is the same as html_title.
-#html_short_title = None
+# html_short_title = None
# The name of an image file (relative to this directory) to place at the top
# of the sidebar.
-#html_logo = None
+# html_logo = None
# The name of an image file (relative to this directory) to use as a favicon of
-# the docs. This file should be a Windows icon file (.ico) being 16x16 or 32x32
+# the docs. This file should be a Windows icon file (.ico) being 16x16 or 32x32
# pixels large.
-#html_favicon = None
+# html_favicon = None
# Add any paths that contain custom static files (such as style sheets) here,
# relative to this directory. They are copied after the builtin static files,
# so a file named "default.css" will overwrite the builtin "default.css".
-html_static_path = ['_static']
+# html_static_path = ['_static']
# Add any extra paths that contain custom files (such as robots.txt or
# .htaccess) here, relative to this directory. These files are copied
# directly to the root of the documentation.
-#html_extra_path = []
+# html_extra_path = []
# If not None, a 'Last updated on:' timestamp is inserted at every page
# bottom, using the given strftime format.
# The empty string is equivalent to '%b %d, %Y'.
-#html_last_updated_fmt = None
+# html_last_updated_fmt = None
# If true, SmartyPants will be used to convert quotes and dashes to
# typographically correct entities.
-#html_use_smartypants = True
+# html_use_smartypants = True
# Custom sidebar templates, maps document names to template names.
-#html_sidebars = {}
+# html_sidebars = {}
# Additional templates that should be rendered to pages, maps page names to
# template names.
-#html_additional_pages = {}
+# html_additional_pages = {}
# If false, no module index is generated.
-#html_domain_indices = True
+# html_domain_indices = True
# If false, no index is generated.
-#html_use_index = True
+# html_use_index = True
# If true, the index is split into individual pages for each letter.
-#html_split_index = False
+# html_split_index = False
# If true, links to the reST sources are added to the pages.
-#html_show_sourcelink = True
+# html_show_sourcelink = True
# If true, "Created using Sphinx" is shown in the HTML footer. Default is True.
-#html_show_sphinx = True
+# html_show_sphinx = True
# If true, "(C) Copyright ..." is shown in the HTML footer. Default is True.
-#html_show_copyright = True
+# html_show_copyright = True
# If true, an OpenSearch description file will be output, and all pages will
# contain a tag referring to it. The value of this option must be the
# base URL from which the finished HTML is served.
-#html_use_opensearch = ''
+# html_use_opensearch = ''
# This is the file name suffix for HTML files (e.g. ".xhtml").
-#html_file_suffix = None
+# html_file_suffix = None
# Language to be used for generating the HTML full-text search index.
# Sphinx supports the following languages:
# 'da', 'de', 'en', 'es', 'fi', 'fr', 'hu', 'it', 'ja'
# 'nl', 'no', 'pt', 'ro', 'ru', 'sv', 'tr', 'zh'
-#html_search_language = 'en'
+# html_search_language = 'en'
# A dictionary with options for the search language support, empty by default.
# 'ja' uses this config value.
# 'zh' user can custom change `jieba` dictionary path.
-#html_search_options = {'type': 'default'}
+# html_search_options = {'type': 'default'}
# The name of a javascript file (relative to the configuration directory) that
# implements a search results scorer. If empty, the default will be used.
-#html_search_scorer = 'scorer.js'
+# html_search_scorer = 'scorer.js'
# Output file base name for HTML help builder.
-htmlhelp_basename = 'iris-gribdoc'
+htmlhelp_basename = "iris-gribdoc"
# -- Options for LaTeX output ---------------------------------------------
latex_elements = {
-# The paper size ('letterpaper' or 'a4paper').
-#'papersize': 'letterpaper',
-
-# The font size ('10pt', '11pt' or '12pt').
-#'pointsize': '10pt',
-
-# Additional stuff for the LaTeX preamble.
-#'preamble': '',
-
-# Latex figure (float) alignment
-#'figure_align': 'htbp',
+ # The paper size ('letterpaper' or 'a4paper').
+ # 'papersize': 'letterpaper',
+ # The font size ('10pt', '11pt' or '12pt').
+ # 'pointsize': '10pt',
+ # Additional stuff for the LaTeX preamble.
+ # 'preamble': '',
+ # Latex figure (float) alignment
+ # 'figure_align': 'htbp',
}
# Grouping the document tree into LaTeX files. List of tuples
# (source start file, target name, title,
# author, documentclass [howto, manual, or own class]).
latex_documents = [
- (master_doc, 'iris-grib.tex', u'iris-grib Documentation',
- u'Met Office', 'manual'),
+ (master_doc, "iris-grib.tex", "iris-grib Documentation", "Met Office", "manual"),
]
# The name of an image file (relative to this directory) to place at the top of
# the title page.
-#latex_logo = None
+# latex_logo = None
# For "manual" documents, if this is true, then toplevel headings are parts,
# not chapters.
-#latex_use_parts = False
+# latex_use_parts = False
# If true, show page references after internal links.
-#latex_show_pagerefs = False
+# latex_show_pagerefs = False
# If true, show URL addresses after external links.
-#latex_show_urls = False
+# latex_show_urls = False
# Documents to append as an appendix to all manuals.
-#latex_appendices = []
+# latex_appendices = []
# If false, no module index is generated.
-#latex_domain_indices = True
+# latex_domain_indices = True
# -- Options for manual page output ---------------------------------------
# One entry per manual page. List of tuples
# (source start file, name, description, authors, manual section).
-man_pages = [
- (master_doc, 'iris-grib', u'iris-grib Documentation',
- [author], 1)
-]
+man_pages = [(master_doc, "iris-grib", "iris-grib Documentation", [author], 1)]
# If true, show URL addresses after external links.
-#man_show_urls = False
+# man_show_urls = False
# -- Options for Texinfo output -------------------------------------------
@@ -272,23 +264,48 @@
# (source start file, target name, title, author,
# dir menu entry, description, category)
texinfo_documents = [
- (master_doc, 'iris-grib', u'iris-grib Documentation',
- author, 'iris-grib', 'One line description of project.',
- 'Miscellaneous'),
+ (
+ master_doc,
+ "iris-grib",
+ "iris-grib Documentation",
+ author,
+ "iris-grib",
+ "One line description of project.",
+ "Miscellaneous",
+ ),
]
# Documents to append as an appendix to all manuals.
-#texinfo_appendices = []
+# texinfo_appendices = []
# If false, no module index is generated.
-#texinfo_domain_indices = True
+# texinfo_domain_indices = True
# How to display URL addresses: 'footnote', 'no', or 'inline'.
-#texinfo_show_urls = 'footnote'
+# texinfo_show_urls = 'footnote'
# If true, do not generate a @detailmenu in the "Top" node's menu.
-#texinfo_no_detailmenu = False
+# texinfo_no_detailmenu = False
# Example configuration for intersphinx: refer to the Python standard library.
-intersphinx_mapping = {'https://docs.python.org/': None}
+intersphinx_mapping = {
+ "python": ("https://docs.python.org/3/", None),
+ "iris": ("https://scitools-iris.readthedocs.io/en/stable/", None),
+}
+
+# -- apidoc extension ---------------------------------------------------------
+# See https://www.sphinx-doc.org/en/master/usage/extensions/apidoc.html
+docs_path = Path(__file__).parent.absolute()
+main_module_rootpath = (docs_path.parent / "src" / "iris_grib").absolute()
+moduledir_str = str(main_module_rootpath)
+destpath_str = str(docs_path / "api")
+moduletestdir_str = str(main_module_rootpath / "tests")
+apidoc_modules = [
+ {
+ "path": moduledir_str,
+ "destination": "./api",
+ "exclude_patterns": [moduletestdir_str],
+ "module_first": True,
+ },
+]
diff --git a/docs/explanation/phenom_translation.rst b/docs/explanation/phenom_translation.rst
new file mode 100644
index 00000000..0759477f
--- /dev/null
+++ b/docs/explanation/phenom_translation.rst
@@ -0,0 +1,33 @@
+Phenomenon translation
+======================
+
+``iris-grib`` attempts to translate between CF phenomenon identities
+(i.e. 'standard_name' and possibly 'long_name' attributes), and GRIB parameter codes,
+when converting cubes to or from the GRIB format.
+
+A set of tables define known CF translations for GRIB1 and GRIB2 parameters, and can be
+interrogated with the functions in :mod:`iris_grib.grib_phenom_translation`.
+
+Parameter loading record
+------------------------
+All cubes loaded from GRIB have a ``GRIB_PARAM`` attribute, which records the parameter
+encodings present in the original file message.
+
+Examples :
+
+* ``"GRIB2:d000c003n005"`` represents GRIB2, discipline=0 ("Meteorological products"),
+ category=3 ("Mass") and indicatorOfParameter=5 ("Geopotential height (gpm)").
+
+ * This translates to a standard_name and units of "geopotential_height / m"
+
+* ``"GRIB1:t002c007n033"`` is GRIB1 with table2Version=2, centre=7
+ ("US National Weather Service - NCEP (WMC)"), and indicatorOfParameter=33
+ ("U-component of wind m s**-1").
+
+ * This translates to a standard_name and units of "x_wind / m s-1".
+
+Parameter saving control
+------------------------
+When a cube has a ``GRIB_PARAM`` attribute, as described above, this controls what the
+relevant message keys are set to on saving.
+(N.B. at present applies only to GRIB2, since we don't support GRIB1 saving)
diff --git a/docs/how_to/get_started.rst b/docs/how_to/get_started.rst
new file mode 100644
index 00000000..98538453
--- /dev/null
+++ b/docs/how_to/get_started.rst
@@ -0,0 +1,21 @@
+Getting Started
+===============
+
+To ensure all ``iris-grib`` dependencies, it is sufficient to have installed
+:mod:`Iris ` itself, and
+`ecCodes `_ .
+
+The simplest way to install is with
+`conda `_ , using the
+`package on conda-forge `_ ,
+with the command::
+
+ $ conda install -c conda-forge iris-grib
+
+Pip can also be used, to install from the
+`package on PyPI `_ ,
+with the command::
+
+ $ pip install iris-grib
+
+Development sources are hosted at ``_ .
diff --git a/docs/how_to/modify_during_load.rst b/docs/how_to/modify_during_load.rst
new file mode 100644
index 00000000..84fb6790
--- /dev/null
+++ b/docs/how_to/modify_during_load.rst
@@ -0,0 +1,45 @@
+How to modify GRIB content during loading
+=========================================
+
+See also: :doc:`/tutorial/load_save_api`.
+
+.. testsetup::
+
+ import iris
+ import iris_grib
+ import warnings
+
+ warnings.simplefilter("ignore")
+ cube = iris.load_cube(iris.sample_data_path("A1B_north_america.nc"))
+ cube.coord("forecast_period").guess_bounds()
+ filename = "testfile.grib"
+ iris.save(cube, filename, saver="grib2")
+
+Here is a basic example of how you can modify the GRIB messages being loaded,
+and how to turn those modified messages into Iris cubes.
+
+ >>> import iris
+ >>> from iris.cube import CubeList
+ >>> from iris_grib import GribMessage, load_pairs_from_fields
+ >>>
+ >>> def adjust_message(msg: GribMessage) -> GribMessage:
+ ... # Advance all time steps by 1 hour.
+ ... if msg.sections[0]["editionNumber"] == 2:
+ ... s1 = msg.sections[1]
+ ... s1["hour"] += 1
+ ... s4 = msg.sections[4]
+ ... s4["hourOfEndOfOverallTimeInterval"] += 1
+ ... return msg
+
+ >>> original = iris.load_cube(filename)
+ >>> fields = GribMessage.messages_from_filename(filename)
+ >>> fields = (adjust_message(msg) for msg in fields)
+ >>> cubes = CubeList(cube for cube, _ in load_pairs_from_fields(fields))
+ >>> modified = cubes.combine_cube()
+
+Compare the final 5 time steps of the original and modified cubes:
+
+ >>> print(original.coord("time").points[-5:])
+ [1084524. 1093236. 1101936. 1110636. 1119336.]
+ >>> print(modified.coord("time").points[-5:])
+ [1084525. 1093237. 1101937. 1110637. 1119337.]
diff --git a/docs/how_to/simple_grib_io.rst b/docs/how_to/simple_grib_io.rst
new file mode 100644
index 00000000..6d5c4fd0
--- /dev/null
+++ b/docs/how_to/simple_grib_io.rst
@@ -0,0 +1,29 @@
+Simple GRIB Loading and Saving with Iris
+========================================
+
+You can use the functionality provided by ``iris-grib`` directly within Iris
+without having to explicitly import ``iris-grib``, as long as you have both Iris
+and ``iris-grib`` installed in your Python environment.
+
+**This is the preferred route if no special control is required.**
+
+.. testsetup::
+
+ import iris
+ import iris_grib
+ import warnings
+
+ warnings.simplefilter("ignore")
+ cube = iris.load_cube(iris.sample_data_path("rotated_pole.nc"))
+ iris.save(cube, "testfile.grib", saver="grib2")
+
+For example, to load GRIB data :
+
+ >>> cube = iris.load_cube('testfile.grib')
+
+Similarly, you can save cubes to a GRIB file directly from Iris :
+
+ >>> iris.save(cube, 'my_file.grib2')
+
+.. note::
+ As the filename suggests, **only saving to GRIB2 is currently supported**.
diff --git a/docs/index.rst b/docs/index.rst
index 2ef2f65f..1e1de2bd 100644
--- a/docs/index.rst
+++ b/docs/index.rst
@@ -1,22 +1,91 @@
.. iris-grib documentation master file, created by
sphinx-quickstart on Fri May 13 11:48:28 2016.
You can adapt this file completely to your liking, but it should at least
- contain the root `toctree` directive.
+ contain the root ``toctree`` directive.
-Welcome to iris-grib's documentation!
-=====================================
+Iris-grib v0.22
+===============
+
+The library ``iris-grib`` provides functionality for converting between weather and
+climate datasets that are stored as GRIB files and Iris :class:`~iris.cube.Cube`\s.
+GRIB files can be loaded as Iris cubes using ``iris-grib`` so that you can use Iris
+for analysing and visualising the contents of the GRIB files. Iris cubes can also be
+saved to GRIB edition-2 files using ``iris-grib``.
+
+
+New here?
+---------
+
+We recommend:
+
+- :doc:`/how_to/get_started`
+- :doc:`/how_to/simple_grib_io`
+
+
+Navigating this site
+--------------------
+
+.. list-table::
+ :header-rows: 1
+ :stub-columns: 1
+
+ * -
+ - Description
+ - supports ...
+ - via ...
+ * - Tutorials
+ - Guided lessons for understanding a topic.
+ - study
+ - action
+ * - Explanation
+ - In-depth discussion for understanding concepts.
+ - study
+ - theory
+ * - How-To Guides
+ - Step by step instructions for achieving a specific goal.
+ - work
+ - action
+ * - Reference
+ - Concise information to look up when needed.
+ - work
+ - theory
+
+Read more: `Diataxis.fr`_
-Contents:
.. toctree::
- :maxdepth: 2
+ :maxdepth: 1
+ :caption: Tutorials
- ref/index
+ tutorial/load_save_api
-Indices and tables
-==================
+.. toctree::
+ :maxdepth: 1
+ :caption: Explanation
+
+ explanation/phenom_translation
+
+.. toctree::
+ :maxdepth: 1
+ :caption: How-To Guides
+
+ how_to/get_started
+ how_to/simple_grib_io
+ how_to/modify_during_load
+
+.. toctree::
+ :maxdepth: 1
+ :caption: Reference
+
+ reference/release_notes
+ Iris-grib API
+
+
+See also
+--------
* :ref:`genindex`
* :ref:`modindex`
-* :ref:`search`
+
+.. _Diataxis.fr: https://diataxis.fr/
diff --git a/docs/make.bat b/docs/make.bat
index d485d3bc..b567efac 100644
--- a/docs/make.bat
+++ b/docs/make.bat
@@ -36,7 +36,6 @@ if "%1" == "help" (
echo. changes to make an overview over all changed/added/deprecated items
echo. xml to make Docutils-native XML files
echo. pseudoxml to make pseudoxml-XML files for display purposes
- echo. linkcheck to check all external links for integrity
echo. doctest to run all doctests embedded in the documentation if enabled
echo. coverage to run coverage check of the documentation if enabled
echo. dummy to check syntax errors of document sources
@@ -227,15 +226,6 @@ if "%1" == "changes" (
goto end
)
-if "%1" == "linkcheck" (
- %SPHINXBUILD% -b linkcheck %ALLSPHINXOPTS% %BUILDDIR%/linkcheck
- if errorlevel 1 exit /b 1
- echo.
- echo.Link check complete; look for any errors in the above output ^
-or in %BUILDDIR%/linkcheck/output.txt.
- goto end
-)
-
if "%1" == "doctest" (
%SPHINXBUILD% -b doctest %ALLSPHINXOPTS% %BUILDDIR%/doctest
if errorlevel 1 exit /b 1
diff --git a/docs/ref/index.rst b/docs/ref/index.rst
deleted file mode 100644
index 7e39e274..00000000
--- a/docs/ref/index.rst
+++ /dev/null
@@ -1,5 +0,0 @@
-Reference documentation
-=======================
-
-.. automodule:: iris_grib
- :members:
diff --git a/docs/reference/release_notes.rst b/docs/reference/release_notes.rst
new file mode 100644
index 00000000..381a87f6
--- /dev/null
+++ b/docs/reference/release_notes.rst
@@ -0,0 +1,820 @@
+.. _release_notes:
+
+Release Notes
+=============
+
+What's new in iris-grib v0.23.0
+-------------------------------
+
+:Release: 0.23.0
+:Date: TBC
+
+Internal
+^^^^^^^^
+* `@trexfeathers `_ switched the link check CI
+ to be the standard SciTools overnight job using Lychee.
+ `(PR#795) `_
+
+
+What's new in iris-grib v0.22.0
+-------------------------------
+
+:Release: 0.22.0
+:Date: 24 March 2026
+
+Features
+^^^^^^^^
+* `@MoseleyS `_ added support for loading GRIB2 data
+ found in the Met Office wholesale Weather Data Hub and CEDA archive.
+ `(PR#647) `_
+
+* `@andrewgryan `_ and
+ `@trexfeathers `_ added saving support for
+ Earth shape 6 - fixed radius 6,371,229 m.
+ `(PR#712) `_
+
+
+Fixes
+^^^^^
+* `@pp-mo `_ fixed the setting of
+ :class:`~iris_grib.grib_message.GribMessage` values, making it possible to
+ set values for keys that have not been read yet.
+ `(PR#766) `_
+
+* `@pp-mo `_ fixed a problem of scaled integers
+ rounding incorrectly, resulting from the transition to NumPy v2.
+ `(PR#767) `_
+
+
+Documentation
+^^^^^^^^^^^^^
+* `@trexfeathers `_ reorganised the
+ documentation to be easier to navigate, using the Diataxis framework.
+ `(PR#768) `_
+
+Dependencies
+^^^^^^^^^^^^
+* `@trexfeathers `_ updated the supported
+ Python versions to be 3.12, 3.13, 3.14; in line with
+ `SPEC 0 `_.
+ `(PR#770) `_
+
+* `@trexfeathers `_ updated the minimum
+ supported Iris version to >=3.10, owing to some internal changes in Iris-grib.
+ `(PR#770) `_
+
+* Iris-grib is continually updated to test against the latest version of its
+ dependencies, allowing us to respond promptly to any breaking changes, and to
+ provide a record of what changed and when.
+
+* Iris-grib is continually updated to follow the latest coding standard
+ conventions in scientific Python - via
+ `repo-review `_
+ and `pre-commit `_ - maximising the ease of
+ contribution and maintenance.
+
+
+Internal
+^^^^^^^^
+* `@ESadek-MO `_ improved Pickle testing to not
+ rely on Iris, and to use PyTest.
+ `(PR#620) `_
+
+* `@stephenworsley `_ increased Iris-grib's
+ compliance with Scientific Python's
+ `repo-review `_.
+ `(PR#638) `_
+
+* `@pp-mo `_ added testing for reading/writing
+ ``GRIB_PARAM`` attributes in NetCDF files.
+ `(PR#677) `_
+
+* Various improvements to coding standards ('linting'):
+
+ * `PR#599 `_
+ * `PR#625 `_
+ * `PR#667 `_
+ * `PR#694 `_
+ * `PR#758 `_
+
+* `@pp-mo `_ dropped the outdated use of the
+ ``np.floating`` type. `PR#664 `_
+
+* `@trexfeathers `_ adapted tests for upstream
+ changes in ecCodes test data (ECC-2110).
+ `(PR#716) `_
+
+* `@trexfeathers `_ adapted tests for an
+ upstream fix in cf-time date2num conversion (cftime#355).
+ `(PR#748) `_
+
+* `@pp-mo `_ and
+ `@trexfeathers `_ are working through a
+ large refactor so that GRIB1 and GRIB2 support share as much code as possible.
+ Progress in this release: `PR#738 `_
+
+* `@ukmo-ccbunney `_ and
+ `@ESadek-MO `_ aligned ``CITATION.cff`` and
+ ``MANIFEST.in`` with agreed SciTools standards.
+ `(PR#675) `_,
+ `(PR#676) `_
+
+
+New Contributors
+^^^^^^^^^^^^^^^^
+Welcome to
+
+* `@MoseleyS `_
+* `@andrewgryan `_
+* `@ukmo-ccbunney `_
+
+
+What's new in iris-grib v0.21.0
+-------------------------------
+
+:Release: 0.21.0
+:Date: 07 January 2025
+
+Dependencies
+^^^^^^^^^^^^
+* `@pp-mo `_ added a fix to support ecCodes versions >= 2.38
+ `(PR#578) `_
+* `@pp-mo `_ fixed tests to work with numpy versions >= 2.0
+ `(PR#580) `_
+
+Internal
+^^^^^^^^
+* `@trexfeathers `_ added integration tests to ensure
+ code coverage of GRIB1 loading code, to enable future refactoring.
+ `(ISSUE#488) `_,
+ `(PR#583) `_
+* `@pp-mo `_ updated repository automation to meet current
+ SciTools code quality recommendations
+ `(PR#568) `_,
+ `(PR#572) `_
+
+
+What's new in iris-grib v0.20.0
+-------------------------------
+
+:Release: 0.20.0
+:Date: 29 August 2024
+
+Features
+^^^^^^^^
+* `@abooton `_ added support for saving data on a
+ Lambert Azimuthal Equal Area (LAEA) projection, as grid definition template 3.140.
+ `(ISSUE#344) `_,
+ `(PR#343) `_
+
+* `@trexfeathers `_,
+ `@mo-marqh `_ and
+ `@pp-mo `_ added support for production definition template
+ 4.6, i.e. percentile forecasts.
+ `(PR#401) `_,
+ `(PR#295) `_,
+ `(PR#271) `_
+
+* `@pp-mo `_ expanded the use of the "GRIB_PARAM"
+ attributes to GRIB1 loading, and documented it more thoroughly.
+ `(ISSUE#330) `_,
+ `(PR#402) `_
+
+* `@DPeterK `_ and
+ `@trexfeathers `_ added saving support for
+ grid definition template 20 - polar stereographic.
+ `(ISSUE#122) `_,
+ `(PR#405) `_
+
+
+Documentation
+^^^^^^^^^^^^^
+* `@tkknight `_ fixed docs building on ReadTheDocs, and
+ enabled a test docs-build for each individual PR.
+ `(ISSUE#365) `_,
+ `(PR#366) `_
+
+* `@tkknight `_ made docs builds treat warnings as errors.
+ `(PR#471) `_
+
+* `@pp-mo `_ reworked the main docs page to :
+ headline basic load + save with Iris, rather than lower-level functions;
+ better explain load-pairs and save-pairs usage; make all usage examples into
+ doctests.
+ `(ISSUE#398) `_,
+ `(PR#402) `_
+
+* `@bjlittle `_ updated the readme, replacing README.rst
+ with README.md and adding a logo .
+ `(PR#440) `_,
+ `(PR#447) `_
+
+* `@tkknight `_ fixed the display formatting of linux
+ commands.
+ `(PR#455) `_
+
+
+Dependencies
+^^^^^^^^^^^^
+* `@pp-mo `_ enabled support for
+ `eccodes v2.36 `_.
+ Eccodes v2.36 has implemented some backwards incompatible changes :
+ The ``indicatorOfUnitOfTimeRange`` key was removed, to be replaced with
+ ``indicatorOfUnitForForecastTime`` (but only in GRIB v2 messages, not GRIB 1);
+ and the ``iScansPositively`` and ``jScansPositively`` keys became read-only.
+ The resulting changes mean **we now only support eccodes >=2.33**.
+ `(PR#504) `_
+
+* `@bjlittle `_ added iris-sample-data as a dependency,
+ as required for doctests.
+ `(PR#413) `_
+
+* `@pp-mo `_ made essential changes for compatibility with
+ Iris >= 3.10.
+ `(PR#463) `_
+
+
+Internal
+^^^^^^^^
+* `@trexfeathers `_ updated CONTRIBUTING.md in line with the
+ newer v5 SciTools CLA. `(PR#371) `_
+
+* `@pp-mo `_ updated an obsolete license header in one test.
+ `(PR#374) `_
+
+* `@trexfeathers `_ and
+ `@pp-mo `_ added a pre-commit configuration and got all
+ checks passing.
+ `(ISSUE#388) `_,
+ `(PR#400) `_,
+ `(PR#406) `_
+
+* `@HGWright `_ and
+ `@trexfeathers `_ replaced setup.py with
+ pyproject.toml.
+ `(ISSUE#387) `_,
+ `(PR#408) `_,
+ `(PR#429) `_
+
+* `@stephenworsley `_ configured for MyPy checking via
+ pre-commit.
+ `(ISSUE#386) `_,
+ `(PR#407) `_
+
+* `@ESadek-MO `_ and
+ `@bjlittle `_ migrated CI testing from Cirrus to
+ GitHub Actions.
+ `(ISSUE#340) `_,
+ `(PR#415) `_,
+ `(PR#425) `_,
+ `(PR#432) `_
+
+* `@trexfeathers `_ and
+ `@HGWright `_ adopted Ruff for code style checking.
+ `(ISSUE#384) `_,
+ `(PR#430) `_,
+ `(PR#419) `_
+
+* `@bjlittle `_ migrated the test runs from
+ nose to pytest.
+ `(ISSUE#253) `_,
+ `(ISSUE#412) `_,
+ `(PR#420) `_,
+ `(PR#424) `_
+
+* `@stephenworsley `_ removed the now-redundant
+ _iris_mercator_support.py.
+ `(ISSUE#431) `_,
+ `(PR#433) `_,
+ `(PR#435) `_
+
+* `@bjlittle `_ added build manifest checking in GHA.
+ `(PR#427) `_,
+ `(PR#436) `_,
+ `(PR#441) `_
+
+* `@bjlittle `_ added dependabot checking.
+ `(PR#426) `_
+
+* `@bjlittle `_ removed 'wheel' dependency from build
+ system, as-per
+ `repo-review `_.
+ `(PR#437) `_
+
+* `@bjlittle `_ fixed blacken-docs url in pre-commit,
+ as per
+ `repo-review `_.
+ `(PR#438) `_
+
+* `@bjlittle `_ provided a custom per-commit.ci message,
+ as per
+ `repo-review `_.
+ `(PR#439) `_
+
+* `@pp-mo `_ removed obsolete workaround routines relating to
+ older eccodes versions.
+ `(ISSUE#239) `_,
+ `(PR#410) `_
+
+* `@HGWright `_ implemented version handling with
+ setuptools.scm .
+ `(ISSUE#418) `_,
+ `(PR#444) `_
+
+* `@bjlittle `_ moved the top-level ``./iris_grib`` folder
+ to ``./src/iris_grib``, in line with modern practice, as per
+ `repo-review `_.
+ `(ISSUE#421) `_,
+ `(PR#450) `_
+
+* `@bjlittle `_ adopted .git-blame-ignore-revs to exclude
+ some very noisy PRs from file "blame" views
+ `(PR#452) `_
+
+* `@bjlittle `_ dropped Python 3.9 support and added 3.12,
+ in accordance with `nep29 `_.
+ `(PR#453) `_
+
+* `@bjlittle `_ updated all optional dependency
+ requirements, and added codecov support.
+ `(PR#454) `_,
+ `(PR#459) `_
+
+* `@bjlittle `_ added repository health checking with
+ `repo-review `_
+ via pre-commit.
+ `(ISSUE#392) `_,
+ `(PR#456) `_
+
+* `@bjlittle `_ added a CODE_OF_CONDUCT.md .
+ `(PR#460) `_
+
+* `@bjlittle `_ aligned .gitignore with a suggested
+ standard form
+ `(PR#461) `_
+
+* `@bjlittle `_ fixed some spelling errors to satisfy
+ codespell
+ `(PR#479) `_
+
+* `@githubalexliu `_ fixed a problem with the MyPy
+ checking.
+ `(ISSUE#496) `_,
+ `(PR#497) `_
+
+* `@trexfeathers `_ aligned the pre-commit-config with
+ the SciTools "reference" version.
+ `(PR#464) `_,
+
+
+New Contributors
+^^^^^^^^^^^^^^^^
+Welcome to
+
+* `@abooton `_
+* `@githubalexliu `_
+* `@stephenworsley `_
+* `@tkknight `_ fixed the display formatting of linux
+* `@DPeterK `_
+* `@ESadek-MO `_
+* `@HGWright `_
+
+
+What's new in iris-grib v0.19.1
+-------------------------------
+
+:Release: 0.19.1
+:Date: 14 December 2023
+
+Documentation
+^^^^^^^^^^^^^
+* `@pp-mo `_ updated the release notes with v0.19 changes.
+ `(PR#370) `_
+
+
+What's new in iris-grib v0.19.0
+-------------------------------
+
+:Release: 0.19.0
+:Date: 16 November 2023
+
+See also :
+`GitHub v0.19.0 release page `_
+
+Features
+^^^^^^^^
+* `@lbdreyer `_ and
+ `@pp-mo `_ (reviewer) modified the loading of GRIB
+ messages with an unrecognised fixed surface type. These are now loaded in as
+ an unnamed coordinate with an attribute called GRIB_fixed_surface_type.
+ iris-grib will also save out cubes with this attribute as the given fixed
+ surface type. `(PR#318) `_
+
+* `@trexfeathers `_ extended Transverse Mercator
+ to support negative scanning.
+ `(PR#296) `_
+
+* `@trexfeathers `_ added a number of new GRIB-CF
+ mappings, i.e. translations from GRIB parameters to CF standard names and vice-versa.
+ `(PR#297) `_
+
+Bugs Fixed
+^^^^^^^^^^
+* `@lbdreyer `_ and
+ `@pp-mo `_ (reviewer) modified the GRIB1 loading
+ code so that it no longer assumes a spherical Earth with radius of 6371229 m
+ and instead uses the resolutionAndComponentFlag to determine the shape of the
+ Earth. This can either be a spherical Earth with radius of 6367470 m or an
+ oblate spheroid, the latter of which is not supported. Note that this change
+ in Earth's radius will result in a different coordinate system and may also
+ affect the coordinate values.
+ `(PR#316) `_
+* `@s-boardman `_ corrected the calculation of bounded
+ forecast periods in GRIB1 loading.
+ `(PR#322) `_
+* `@david-bentley `_ fixed the calculation of message
+ file offsets to work in Windows as well as Linux, which was causing load failures.
+ `(PR#287) `_
+* `@bjlittle `_ fixed an error that occurred when a
+ message had all-missing data points.
+ `(PR#362) `_
+
+
+Internal
+^^^^^^^^
+* `@lbdreyer `_ relicensed the repo from LGPL-3 to BSD-3.
+ `(PR#359) `_
+
+Dependencies
+^^^^^^^^^^^^
+* now requires Python version >= 3.9
+* replaced deprecated eccodes-python PyPI package with new eccodes by @valeriupredoi in #357
+* `@valeriupredoi `_ replaced the deprecated
+ eccodes-python PyPI package with eccodes.
+ `(PR#357) `_
+
+New Contributors
+^^^^^^^^^^^^^^^^
+Welcome to
+
+* `@s-boardman `_
+* `@david-bentley `_
+* `@valeriupredoi `_
+
+
+What's new in iris-grib v0.18.0
+-------------------------------
+
+:Release: 0.18.0
+:Date: 14 March 2022
+
+Bugs Fixed
+^^^^^^^^^^
+* `@lbdreyer `_ made various updates to allow
+ iris-grib to work with the latest versions of
+ `iris `_,
+ `cf-units `_,
+ `ecCodes `_ and
+ `cartopy `_, including casting
+ the usage of :meth:`cf_units.Unit.date2num` as float. setting and setting the
+ values of some missing keys using ``gribapi.GRIB_MISSING_LONG``.
+ `(PR#288) `_
+
+
+Dependencies
+^^^^^^^^^^^^
+* now requires Python version >= 3.8
+
+
+Internal
+^^^^^^^^
+* `@TomDufall `_ updated the code so that it was
+ `flake8 `_ compliant and enabled flake8
+ checks to the CI.
+ `(PR#271) `_
+
+
+What's new in iris-grib v0.17.1
+-------------------------------
+
+:Release: 0.17.1
+:Date: 8 June 2021
+
+Bugs Fixed
+^^^^^^^^^^
+
+* `@TomDufall `_ removed the empty slice
+ handling (originally added in v0.15.1) as this used
+ iris.util._array_slice_ifempty which was removed in Iris v3.0.2 and is no
+ longer necessary.
+ `(PR#270) `_
+
+
+Dependencies
+^^^^^^^^^^^^
+
+* now requires Iris version >= 3.0.2.
+
+* now requires Python version >= 3.7.
+
+
+
+What's new in iris-grib v0.17
+-----------------------------
+
+:Release: 0.17.0
+:Date: 18 May 2021
+
+Features
+^^^^^^^^
+
+* `@m1dr `_ added support for GRIB regulation 92.1.8
+ for loading GRIB files where the longitude increment is not given.
+ `(PR#261) `_
+
+* `@lbdreyer `_ added support for loading grid
+ point and spectral data with CCSDS recommended lossless compression, i.e.
+ data representation template 42.
+ `(PR#264) `_
+
+
+Internal
+^^^^^^^^
+
+* `@jamesp `_ moved CI testing to Cirrus CI.
+ `(PR#250) `_
+
+
+
+What's new in iris-grib v0.16
+-----------------------------
+
+:Release: 0.16.0
+:Date: 27 Jan 2021
+
+Features
+^^^^^^^^
+
+* `@tpowellmeto `_ added support for loading
+ data on a "Lambert Azimuthal Equal Area Projection",
+ i.e. grid definition template 3.140.
+ `(PR#187) `_
+
+* `@bjlittle `_ made all the tests runnable for a
+ packaged install of iris-grib, where the grib testdata files will be missing.
+ `(PR#212) `_
+
+* `@m1dr `_ added support for loading statistical
+ fields, as encoded in production definition template 3.8, even when the
+ "interval time increment" value is not specified (i.e. set to "missing").
+ `(PR#206) `_
+
+* `@pp-mo `_ ported some tests from Iris, which test
+ grib saving of data loaded from other formats.
+ `(PR#213) `_
+
+* All grib-dependent testing is now contained in iris-grib : **There are no
+ remaining tests in Iris which use grib.**
+
+
+Bugs Fixed
+^^^^^^^^^^
+
+* `@lbdreyer `_ unpinned the python-eccodes
+ version for Travis testing, and added a workaround for a known bug in recent
+ versions of python-eccodes.
+ Previously, we could only test against python-eccodes versions ">=0.9.1,<2".
+ `(PR#208) `_
+
+* `@pp-mo `_ fixed save operations to round off the
+ the integer values of vertical surfaces, instead of truncating them.
+ `(PR#210) `_
+
+* `@pp-mo `_ fixed loading of grid definition
+ template 3.90, "Space view perspective or orthographic grid", which was
+ **broken since Iris 2.3**. This now produces data with an iris
+ `Geostationary `_
+ coordinate system. Prior to Iris 2.3, what is now the Iris 'Geostationary'
+ class was (incorrectly) named "VerticalPerspective" : When that was
+ `corrected in Iris 2.3 `_ , it
+ broke the iris-grib loading, since the data was now incorrectly
+ assigned the "new-style" Iris
+ `VerticalPerspective `_
+ coordinate system, equivalent to the Cartopy
+ `NearsidePerspective `_
+ and Proj
+ `"nsper" `_ .
+ The plotting behaviour of this is now **the same again as before Iris 2.3** :
+ only the Iris coordinate system has changed.
+ `(PR#223) `_
+
+* `@pp-mo