From 9a74b96f31ee60cd1021e55f5aa004865536dcfd Mon Sep 17 00:00:00 2001 From: Charles Kawczynski Date: Mon, 31 Jul 2023 23:15:22 -0700 Subject: [PATCH] Error on NaNs in driver solution --- examples/hybrid/driver.jl | 1 + 1 file changed, 1 insertion(+) diff --git a/examples/hybrid/driver.jl b/examples/hybrid/driver.jl index 6da22f75b4..8e8f423eac 100644 --- a/examples/hybrid/driver.jl +++ b/examples/hybrid/driver.jl @@ -178,6 +178,7 @@ end @info "on a vertical $z_stretch_string grid" walltime = @elapsed sol = OrdinaryDiffEq.solve!(integrator) +any(isnan, sol.u[end]) && error("NaNs found in result.") if is_distributed # replace sol.u on the root processor with the global sol.u if ClimaComms.iamroot(comms_ctx)