From fe1f8ca04bf07c64204cf8d82bf1cc223671c10f Mon Sep 17 00:00:00 2001 From: Jon Wolfe Date: Tue, 2 Apr 2024 12:59:30 -0500 Subject: [PATCH] Add logic to catch issue when partition file assigns 0 cells to a pe --- components/mpas-ocean/src/shared/mpas_ocn_diagnostics.F | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/components/mpas-ocean/src/shared/mpas_ocn_diagnostics.F b/components/mpas-ocean/src/shared/mpas_ocn_diagnostics.F index 288c79db284d..77796959538d 100644 --- a/components/mpas-ocean/src/shared/mpas_ocn_diagnostics.F +++ b/components/mpas-ocean/src/shared/mpas_ocn_diagnostics.F @@ -181,7 +181,7 @@ subroutine ocn_diagnostic_solve(dt, statePool, forcingPool, meshPool, verticalMe call mpas_pool_get_array(forcingPool, 'landIceDraft', landIceDraft) call mpas_pool_get_array(forcingPool, 'landIceFloatingMask', landIceFloatingMask) call mpas_pool_get_array(forcingPool, 'landIceFraction', landIceFraction) - if (landIceFloatingMask(1) == -1) then + if (nCellsAll.gt.0 .AND. landIceFloatingMask(1) == -1) then call mpas_log_write('landIceFloatingMask contains the default value which likely indicates that this field is missing in the initial condition file (e.g. because it is meant for an older E3SM version).', & MPAS_LOG_CRIT) endif