From f38b5b15b1d00f5858542f1627f1d56532792145 Mon Sep 17 00:00:00 2001 From: Willem van Verseveld Date: Tue, 9 Jan 2024 14:09:08 +0100 Subject: [PATCH] changes for compat NCDatasets 0.14 method haskey(::CommonDataModel.MFDataset{NCDataset{Nothing}, 1, String}, ::String) unknown with NCDatasets 0.14. --- src/io.jl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/io.jl b/src/io.jl index 2c08821f8..648fe2f49 100644 --- a/src/io.jl +++ b/src/io.jl @@ -1605,7 +1605,7 @@ Also sorts the vector to be increasing, to match `read_standardized`. function read_x_axis(ds::CFDataset)::Vector{Float64} candidates = ("x", "lon", "longitude") for candidate in candidates - if haskey(ds, candidate) + if haskey(ds.dim, candidate) return sort!(Float64.(ds[candidate][:])) end end @@ -1621,7 +1621,7 @@ Also sorts the vector to be increasing, to match `read_standardized`. function read_y_axis(ds::CFDataset)::Vector{Float64} candidates = ("y", "lat", "latitude") for candidate in candidates - if haskey(ds, candidate) + if haskey(ds.dim, candidate) return sort!(Float64.(ds[candidate][:])) end end