From 05cd0e8b61c345ace00b0a1c91c6e97df9499f78 Mon Sep 17 00:00:00 2001 From: Christian Kanesan Date: Fri, 22 Mar 2024 14:52:20 +0100 Subject: [PATCH] improve messages (#123) --- src/idpi/metadata.py | 2 +- src/idpi/operators/destagger.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/idpi/metadata.py b/src/idpi/metadata.py index 76ef34ce..fd6bab49 100644 --- a/src/idpi/metadata.py +++ b/src/idpi/metadata.py @@ -42,7 +42,7 @@ def override(message: bytes, **kwargs: typing.Any) -> dict[str, typing.Any]: Note that no special consideration is made for maintaining consistency when overriding template definition keys such as productDefinitionTemplateNumber. - Note that the origin components in x and y will be unset. + Note that the origin components in x and y are left untouched. Parameters ---------- diff --git a/src/idpi/operators/destagger.py b/src/idpi/operators/destagger.py index 27746272..7756c81d 100644 --- a/src/idpi/operators/destagger.py +++ b/src/idpi/operators/destagger.py @@ -98,7 +98,7 @@ def _update_grid(field: xr.DataArray, dim: Literal["x", "y"]) -> dict[str, Any]: def _update_vertical(field) -> dict[str, Any]: if field.vcoord_type != "model_level": - raise ValueError("Field.vcoord_type must model_level") + raise ValueError("typeOfLevel must equal generalVertical") return metadata.override( field.message, typeOfLevel="generalVerticalLayer",