From 3f79e1f8f195a8649ec2babd5c19611d2a11bb96 Mon Sep 17 00:00:00 2001 From: Bouwe Andela Date: Mon, 15 Jan 2024 15:45:26 +0100 Subject: [PATCH] Ignore type error --- esmvalcore/preprocessor/_regrid.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/esmvalcore/preprocessor/_regrid.py b/esmvalcore/preprocessor/_regrid.py index 76ce1e5fce..0efe28b01a 100644 --- a/esmvalcore/preprocessor/_regrid.py +++ b/esmvalcore/preprocessor/_regrid.py @@ -1070,7 +1070,9 @@ def extract_levels( set(levels).issubset(set(src_levels.points)): # If all target levels exist in the source cube, simply extract them. name = src_levels.name() - coord_values = {name: lambda cell: cell.point in set(levels)} + coord_values = { + name: lambda cell: cell.point in set(levels) # type: ignore + } constraint = iris.Constraint(coord_values=coord_values) result = cube.extract(constraint) # Ensure the constraint did not fail.