From 9f0f78900c5455579e3cf292b7035a449188522c Mon Sep 17 00:00:00 2001 From: Lars Buntemeyer Date: Tue, 17 Feb 2026 15:03:36 +0100 Subject: [PATCH] added additional medium check for coordinate standard names --- compliance_checker/cf/cf_1_6.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/compliance_checker/cf/cf_1_6.py b/compliance_checker/cf/cf_1_6.py index 126ebfd8..6cc98da8 100644 --- a/compliance_checker/cf/cf_1_6.py +++ b/compliance_checker/cf/cf_1_6.py @@ -2281,6 +2281,10 @@ def check_spatiotemporal_dims_have_coordinate_vars(self, ds): geophysical_variables = self._find_geophysical_vars(ds) for var_name in geophysical_variables: var = ds.variables[var_name] + check_spatiotemporal_dims_coords_std_name = TestCtx( + BaseCheck.MEDIUM, + self.section_titles["4"], + ) check_spatiotemporal_dims_coords = TestCtx( BaseCheck.HIGH, self.section_titles["5.1"], @@ -2299,13 +2303,14 @@ def check_spatiotemporal_dims_have_coordinate_vars(self, ds): coord_var = ds.variables[dim] std_name = getattr(coord_var, "standard_name", None) - check_spatiotemporal_dims_coords.assert_true( + check_spatiotemporal_dims_coords_std_name.assert_true( std_name == expected_standard_names[dim], f"Coordinate variable '{dim}' should have standard_name='{expected_standard_names[dim]}', " f"found: '{std_name}'", ) ret_val.append(check_spatiotemporal_dims_coords.to_result()) + ret_val.append(check_spatiotemporal_dims_coords_std_name.to_result()) return ret_val # IMPLEMENTATION Section 2.5.1 Coordinate Systems and Domain