From b834bacfee8b5f2d1b857c1d821a560a78bb818a Mon Sep 17 00:00:00 2001 From: Michael Hemming Date: Tue, 9 Sep 2025 13:31:59 +1000 Subject: [PATCH 1/3] add flag_values to convert to datatype (bytes in this case) --- aodntools/ncwriter/template.py | 2 +- setup.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/aodntools/ncwriter/template.py b/aodntools/ncwriter/template.py index 62c6c45..6742e0a 100644 --- a/aodntools/ncwriter/template.py +++ b/aodntools/ncwriter/template.py @@ -298,7 +298,7 @@ def create_variables(self, **kwargs): # variable attributes to convert to the same type as the variable # datatype - varattrs_to_convert_to_datatype = ['valid_min', 'valid_max', 'valid_range'] + varattrs_to_convert_to_datatype = ['valid_min', 'valid_max', 'valid_range', 'flag_values'] for varname, varattr in self.variables.items(): if not varattr['_dimensions']: # no kwargs in createVariable diff --git a/setup.py b/setup.py index 5ff7f23..e2a5083 100644 --- a/setup.py +++ b/setup.py @@ -5,7 +5,7 @@ 'numpy>=2.2.4', 'netCDF4>=1.7.2', 'pandas>=2.2.3', - 'xarray>=2023.1.0' + 'xarray>=2023.1.0,xarray<=2025.3.1' ] TESTS_REQUIRE = [ From 0dc457fca461db210117c3e54548455309e96ef9 Mon Sep 17 00:00:00 2001 From: Michael Hemming Date: Tue, 9 Sep 2025 13:33:16 +1000 Subject: [PATCH 2/3] testing --- setup.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/setup.py b/setup.py index e2a5083..6fe856e 100644 --- a/setup.py +++ b/setup.py @@ -5,7 +5,7 @@ 'numpy>=2.2.4', 'netCDF4>=1.7.2', 'pandas>=2.2.3', - 'xarray>=2023.1.0,xarray<=2025.3.1' + 'xarray>=2023.1.0,xarray<=2025.3.1', ] TESTS_REQUIRE = [ From 5f518742a2e8706413f4d76338cbdb15fde6f66a Mon Sep 17 00:00:00 2001 From: Michael Hemming Date: Tue, 9 Sep 2025 13:34:27 +1000 Subject: [PATCH 3/3] testing --- setup.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/setup.py b/setup.py index 6fe856e..baea0ec 100644 --- a/setup.py +++ b/setup.py @@ -5,7 +5,7 @@ 'numpy>=2.2.4', 'netCDF4>=1.7.2', 'pandas>=2.2.3', - 'xarray>=2023.1.0,xarray<=2025.3.1', + 'xarray<=2025.3.1' ] TESTS_REQUIRE = [