From 340012db286be96e74855dfb3aecc97f6ef99bcb Mon Sep 17 00:00:00 2001 From: rem1776 Date: Mon, 29 Dec 2025 11:52:17 -0500 Subject: [PATCH 01/30] update gnu ci to 15.2.1 and test for any failures --- .github/workflows/github_autotools_gnu.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/github_autotools_gnu.yml b/.github/workflows/github_autotools_gnu.yml index a086ccfc20..bee0c0e010 100644 --- a/.github/workflows/github_autotools_gnu.yml +++ b/.github/workflows/github_autotools_gnu.yml @@ -20,7 +20,7 @@ jobs: - conf-flag: --with-mpi=no input-flag: --enable-test-input=/home/unit_tests_input container: - image: ghcr.io/noaa-gfdl/fms/fms-ci-rocky-gnu:13.2.0 + image: ghcr.io/noaa-gfdl/fms-gnu-ci:15.2.1 env: TEST_VERBOSE: 1 DISTCHECK_CONFIGURE_FLAGS: "${{ matrix.conf-flag }} ${{ matrix.input-flag }} ${{ matrix.io-flag }}" @@ -37,7 +37,7 @@ jobs: if: ${{ matrix.conf-flag == '--disable-setting-flags' }} run: ./configure ${DISTCHECK_CONFIGURE_FLAGS} FCFLAGS="-fdefault-real-8 -fdefault-double-8 -fcray-pointer -ffree-line-length-none -I/usr/include $FCFLAGS $DEBUG_FLAGS" || cat config.log - name: Build the library - run: make distcheck + run: make -k distcheck if: ${{ matrix.conf-flag != '--with-mpi=no' }} - name: Build the library (without test suite for serial build) run: make From 5c3f3356cb5fb3642db05c72d477a07c0c8f1d73 Mon Sep 17 00:00:00 2001 From: rem1776 Date: Mon, 29 Dec 2025 11:57:28 -0500 Subject: [PATCH 02/30] update checkout version and cmake action --- .github/workflows/github_autotools_gnu.yml | 2 +- .github/workflows/github_cmake_gnu.yml | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/github_autotools_gnu.yml b/.github/workflows/github_autotools_gnu.yml index bee0c0e010..52e149a3ea 100644 --- a/.github/workflows/github_autotools_gnu.yml +++ b/.github/workflows/github_autotools_gnu.yml @@ -27,7 +27,7 @@ jobs: DEBUG_FLAGS: "-O0 -g -fbounds-check -ffpe-trap=invalid,zero,overflow" # debug compiler flags taken from the mkmf template steps: - name: Checkout code - uses: actions/checkout@v4.2.2 + uses: actions/checkout@v6.0.1 - name: Prepare GNU autoconf for build run: autoreconf -if - name: Configure the build diff --git a/.github/workflows/github_cmake_gnu.yml b/.github/workflows/github_cmake_gnu.yml index 7a45fe80ce..79638e155e 100644 --- a/.github/workflows/github_cmake_gnu.yml +++ b/.github/workflows/github_cmake_gnu.yml @@ -16,12 +16,12 @@ jobs: libyaml-flag: [ "", -DWITH_YAML=on ] build-type: [ "-DCMAKE_BUILD_TYPE=Release", "-DCMAKE_BUILD_TYPE=Debug" ] container: - image: ghcr.io/noaa-gfdl/fms/fms-ci-rocky-gnu:13.2.0 + image: ghcr.io/noaa-gfdl/fms-gnu-ci:15.2.1 env: CMAKE_FLAGS: "${{ matrix.build-type }} ${{ matrix.omp-flags }} ${{ matrix.libyaml-flag }}" steps: - name: Checkout code - uses: actions/checkout@v4.2.2 + uses: actions/checkout@v6.0.1 - name: Generate makefiles with CMake run: | mkdir build From ea64259da32a33794fc415a7bd31c5aed9c842d0 Mon Sep 17 00:00:00 2001 From: Ryan Mulhall <35538242+rem1776@users.noreply.github.com> Date: Mon, 29 Dec 2025 13:13:09 -0500 Subject: [PATCH 03/30] remove invalid character from intel job name --- .github/workflows/github_autotools_intel_oneapi.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/github_autotools_intel_oneapi.yml b/.github/workflows/github_autotools_intel_oneapi.yml index 14f7934509..d8da69c1af 100644 --- a/.github/workflows/github_autotools_intel_oneapi.yml +++ b/.github/workflows/github_autotools_intel_oneapi.yml @@ -6,7 +6,7 @@ concurrency: cancel-in-progress: true jobs: - intel-oneapi-2025.3: + intel-oneapi-2025p3: runs-on: ubuntu-latest container: image: intel/oneapi-hpckit:2025.3.0-0-devel-ubuntu22.04 From b68aa3121d64a033a2d0957219af8b7789e3d1c2 Mon Sep 17 00:00:00 2001 From: rem1776 Date: Tue, 30 Dec 2025 15:23:07 -0500 Subject: [PATCH 04/30] update titles and image names --- .github/workflows/github_autotools_gnu.yml | 13 ++++--------- .../workflows/github_autotools_intel_classic.yml | 3 ++- .github/workflows/github_autotools_intel_oneapi.yml | 2 ++ .github/workflows/github_cmake_gnu.yml | 2 +- .github/workflows/github_coupler_gnu.yml | 4 ++-- .github/workflows/github_linter.yml | 2 +- .github/workflows/github_mom_gnu.yml | 4 ++-- .github/workflows/version.yml | 2 +- test_fms/interpolator/test_interpolator2.sh | 2 +- 9 files changed, 16 insertions(+), 18 deletions(-) diff --git a/.github/workflows/github_autotools_gnu.yml b/.github/workflows/github_autotools_gnu.yml index 52e149a3ea..0d2e5cd3f8 100644 --- a/.github/workflows/github_autotools_gnu.yml +++ b/.github/workflows/github_autotools_gnu.yml @@ -1,6 +1,4 @@ -# 'main' required ci, does a distcheck (builds, tests, check install) -# image created off dockerfile in repo, compile/link flags are set there -name: Build libFMS test with autotools +name: Autotools build and unit testing with GCC on: [push, pull_request] @@ -14,13 +12,13 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - conf-flag: [ --disable-openmp, --disable-setting-flags, --with-mpi=no, --disable-r8-default] + conf-flag: [ --disable-openmp, --with-mpi=no, --disable-r8-default] input-flag: [--with-yaml, --enable-test-input=/home/unit_tests_input] exclude: - conf-flag: --with-mpi=no input-flag: --enable-test-input=/home/unit_tests_input container: - image: ghcr.io/noaa-gfdl/fms-gnu-ci:15.2.1 + image: ghcr.io/noaa-gfdl/fms-gnu-ci:15.1.1 env: TEST_VERBOSE: 1 DISTCHECK_CONFIGURE_FLAGS: "${{ matrix.conf-flag }} ${{ matrix.input-flag }} ${{ matrix.io-flag }}" @@ -33,10 +31,7 @@ jobs: - name: Configure the build if: ${{ matrix.conf-flag != '--disable-setting-flags' }} run: ./configure ${DISTCHECK_CONFIGURE_FLAGS} FCFLAGS="$FCFLAGS $DEBUG_FLAGS" - - name: Configure the build with compiler flags - if: ${{ matrix.conf-flag == '--disable-setting-flags' }} - run: ./configure ${DISTCHECK_CONFIGURE_FLAGS} FCFLAGS="-fdefault-real-8 -fdefault-double-8 -fcray-pointer -ffree-line-length-none -I/usr/include $FCFLAGS $DEBUG_FLAGS" || cat config.log - - name: Build the library + - name: Run distcheck (compiles, tests, and packages) run: make -k distcheck if: ${{ matrix.conf-flag != '--with-mpi=no' }} - name: Build the library (without test suite for serial build) diff --git a/.github/workflows/github_autotools_intel_classic.yml b/.github/workflows/github_autotools_intel_classic.yml index 4b3d892b26..7c7f404126 100644 --- a/.github/workflows/github_autotools_intel_classic.yml +++ b/.github/workflows/github_autotools_intel_classic.yml @@ -1,8 +1,9 @@ +name: Autotools build and unit testing with Intel Classic (weekly) + on: schedule: - cron: '0 0 * * 0' # sundays @ midnight - # cancel running jobs if theres a newer push concurrency: group: ${{ github.workflow }}-${{ github.ref }} diff --git a/.github/workflows/github_autotools_intel_oneapi.yml b/.github/workflows/github_autotools_intel_oneapi.yml index 14f7934509..5c6ddb568d 100644 --- a/.github/workflows/github_autotools_intel_oneapi.yml +++ b/.github/workflows/github_autotools_intel_oneapi.yml @@ -1,3 +1,5 @@ +name: Autotools build and unit testing with Intel Oneapi + on: pull_request # cancel running jobs if theres a newer push diff --git a/.github/workflows/github_cmake_gnu.yml b/.github/workflows/github_cmake_gnu.yml index 79638e155e..af98d0ce0e 100644 --- a/.github/workflows/github_cmake_gnu.yml +++ b/.github/workflows/github_cmake_gnu.yml @@ -1,4 +1,4 @@ -name: Build libFMS with cmake +name: CMake build and unit testing with GCC on: [push, pull_request] diff --git a/.github/workflows/github_coupler_gnu.yml b/.github/workflows/github_coupler_gnu.yml index 4236e43eaf..881c898772 100644 --- a/.github/workflows/github_coupler_gnu.yml +++ b/.github/workflows/github_coupler_gnu.yml @@ -1,4 +1,4 @@ -name: Test coupler build +name: FMScoupler null model build with GCC on: [pull_request] # cancel running jobs if theres a newer push @@ -10,7 +10,7 @@ jobs: coupler-build: runs-on: ubuntu-latest container: - image: ghcr.io/noaa-gfdl/fms/fms-ci-rocky-gnu:13.2.0 + image: ghcr.io/noaa-gfdl/fms-gnu-ci:15.1.1 credentials: username: ${{ github.actor }} password: ${{ secrets.github_token }} diff --git a/.github/workflows/github_linter.yml b/.github/workflows/github_linter.yml index 24fa8969c8..d745250aa3 100644 --- a/.github/workflows/github_linter.yml +++ b/.github/workflows/github_linter.yml @@ -1,4 +1,4 @@ -name: libFMS lint tests +name: Line length and whitespace linter on: [push, pull_request] diff --git a/.github/workflows/github_mom_gnu.yml b/.github/workflows/github_mom_gnu.yml index 7ee5c71449..1aef1bf34a 100644 --- a/.github/workflows/github_mom_gnu.yml +++ b/.github/workflows/github_mom_gnu.yml @@ -1,4 +1,4 @@ -name: Run MOM6 test suite +name: MOM6 test suite with GCC # runs on PR's or when manually triggered on: [workflow_dispatch, pull_request] @@ -12,7 +12,7 @@ jobs: build: runs-on: ubuntu-latest container: - image: ghcr.io/noaa-gfdl/fms/fms-ci-rocky-gnu:13.2.0 + image: ghcr.io/noaa-gfdl/fms-gnu-ci:15.1.1 credentials: username: ${{ github.actor }} password: ${{ secrets.github_token }} diff --git a/.github/workflows/version.yml b/.github/workflows/version.yml index 1b16cf5ed4..0edadd338a 100644 --- a/.github/workflows/version.yml +++ b/.github/workflows/version.yml @@ -1,5 +1,5 @@ -# appends -dev to the version upon release and opens pr # CI won't run on generated PR, easiest workaround is to close + reopen +name: Append version number and create PR on: release: types: [published] diff --git a/test_fms/interpolator/test_interpolator2.sh b/test_fms/interpolator/test_interpolator2.sh index 5a3f76a14a..1afc7dd272 100755 --- a/test_fms/interpolator/test_interpolator2.sh +++ b/test_fms/interpolator/test_interpolator2.sh @@ -51,7 +51,7 @@ cat <<_EOF > input.nml / _EOF -# Run test +# Run test test_expect_success "test interpolator" 'mpirun -n 1 ./test_interpolator' From 3c0041fdbbed069a9faefd02d3e0342bfae6092d Mon Sep 17 00:00:00 2001 From: rem1776 Date: Tue, 30 Dec 2025 15:43:45 -0500 Subject: [PATCH 05/30] fix tag number and add zip to image --- .github/workflows/github_autotools_gnu.yml | 2 +- .github/workflows/github_coupler_gnu.yml | 2 +- .github/workflows/github_mom_gnu.yml | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/github_autotools_gnu.yml b/.github/workflows/github_autotools_gnu.yml index 0d2e5cd3f8..739b5fd865 100644 --- a/.github/workflows/github_autotools_gnu.yml +++ b/.github/workflows/github_autotools_gnu.yml @@ -18,7 +18,7 @@ jobs: - conf-flag: --with-mpi=no input-flag: --enable-test-input=/home/unit_tests_input container: - image: ghcr.io/noaa-gfdl/fms-gnu-ci:15.1.1 + image: ghcr.io/noaa-gfdl/fms-gnu-ci:15.2.1 env: TEST_VERBOSE: 1 DISTCHECK_CONFIGURE_FLAGS: "${{ matrix.conf-flag }} ${{ matrix.input-flag }} ${{ matrix.io-flag }}" diff --git a/.github/workflows/github_coupler_gnu.yml b/.github/workflows/github_coupler_gnu.yml index 881c898772..9552f01959 100644 --- a/.github/workflows/github_coupler_gnu.yml +++ b/.github/workflows/github_coupler_gnu.yml @@ -10,7 +10,7 @@ jobs: coupler-build: runs-on: ubuntu-latest container: - image: ghcr.io/noaa-gfdl/fms-gnu-ci:15.1.1 + image: ghcr.io/noaa-gfdl/fms-gnu-ci:15.2.1 credentials: username: ${{ github.actor }} password: ${{ secrets.github_token }} diff --git a/.github/workflows/github_mom_gnu.yml b/.github/workflows/github_mom_gnu.yml index 1aef1bf34a..aae652f42a 100644 --- a/.github/workflows/github_mom_gnu.yml +++ b/.github/workflows/github_mom_gnu.yml @@ -12,7 +12,7 @@ jobs: build: runs-on: ubuntu-latest container: - image: ghcr.io/noaa-gfdl/fms-gnu-ci:15.1.1 + image: ghcr.io/noaa-gfdl/fms-gnu-ci:15.2.1 credentials: username: ${{ github.actor }} password: ${{ secrets.github_token }} From f911f2a98a7ba9fca27e01f3684b3fb2dcf86619 Mon Sep 17 00:00:00 2001 From: rem1776 Date: Wed, 31 Dec 2025 12:39:55 -0500 Subject: [PATCH 06/30] replace hostname with a more portable command for oversubscribe configure check --- configure.ac | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/configure.ac b/configure.ac index 791f1ca19e..c0959eb021 100644 --- a/configure.ac +++ b/configure.ac @@ -382,10 +382,9 @@ fi AC_CHECK_PROGS([MPI_LAUNCHER],[srun aprun mpirun]) # Check if the launcher can oversubscribe the MPI processes -AS_IF([$MPI_LAUNCHER --oversubscribe hostname >/dev/null 2>&1], \ +AS_IF([$MPI_LAUNCHER --oversubscribe sh -c :], \ [ AC_SUBST([OVERSUBSCRIBE], [--oversubscribe])]) - # Compiler with version information. This consists of the full path # name of the compiler and the reported version number. AC_SUBST([CC_VERSION]) From 3b642ec4a6eede4966e278674bc81bd0e8209162 Mon Sep 17 00:00:00 2001 From: Ryan Mulhall <35538242+rem1776@users.noreply.github.com> Date: Wed, 4 Feb 2026 11:25:22 -0500 Subject: [PATCH 07/30] turn on debug output for test functions --- test_fms/test-lib.sh.in | 2 ++ 1 file changed, 2 insertions(+) diff --git a/test_fms/test-lib.sh.in b/test_fms/test-lib.sh.in index 5f92ad7639..525926fe80 100644 --- a/test_fms/test-lib.sh.in +++ b/test_fms/test-lib.sh.in @@ -24,6 +24,8 @@ # This test package is based on Junio's work for the Git test library. # Thank you Junio. +set -x + # Useful locations top_srcdir='@abs_top_srcdir@@CMAKE_CURRENT_SOURCE_DIR@' top_buildir='@abs_top_builddir@@CMAKE_CURRENT_SOURCE_DIR@' From 3bb9cf31520afa17a5474b918644ebb31bb2d0a6 Mon Sep 17 00:00:00 2001 From: Ryan Mulhall <35538242+rem1776@users.noreply.github.com> Date: Wed, 18 Feb 2026 18:39:51 -0500 Subject: [PATCH 08/30] hardcode oversubscribe option in mpirun function --- test_fms/test-lib.sh.in | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test_fms/test-lib.sh.in b/test_fms/test-lib.sh.in index 525926fe80..100c0922f3 100644 --- a/test_fms/test-lib.sh.in +++ b/test_fms/test-lib.sh.in @@ -96,7 +96,7 @@ die () { mpirun () { # Set the name of the mpi launcher for use in test scripts. local mpi_launcher='@MPI_LAUNCHER@' - local oversubscribe='@OVERSUBSCRIBE@' + local oversubscribe='@OVERSUBSCRIBE@ --oversubscribe' # need to strip off any args that may be included with MPI_LAUNCHER arg for check below to work local mpi_cmd="`echo $mpi_launcher | awk '{print $1;}'`" # Check if running with MPI: if so, the mpi_launcher will point to a command From 4ff70f1972323857509751cc2bd6d959ac0889a3 Mon Sep 17 00:00:00 2001 From: rem1776 Date: Thu, 19 Feb 2026 10:31:37 -0500 Subject: [PATCH 09/30] clean up test function edits and whitespace --- test_fms/interpolator/test_interpolator2.sh | 2 +- test_fms/test-lib.sh.in | 4 +--- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/test_fms/interpolator/test_interpolator2.sh b/test_fms/interpolator/test_interpolator2.sh index 4046c675c4..bd4cf7aab6 100755 --- a/test_fms/interpolator/test_interpolator2.sh +++ b/test_fms/interpolator/test_interpolator2.sh @@ -61,7 +61,7 @@ cat <<_EOF > input.nml / _EOF -# Run test +# Run test test_expect_success "test interpolator" 'mpirun -n 1 ./test_interpolator' diff --git a/test_fms/test-lib.sh.in b/test_fms/test-lib.sh.in index 100c0922f3..5f92ad7639 100644 --- a/test_fms/test-lib.sh.in +++ b/test_fms/test-lib.sh.in @@ -24,8 +24,6 @@ # This test package is based on Junio's work for the Git test library. # Thank you Junio. -set -x - # Useful locations top_srcdir='@abs_top_srcdir@@CMAKE_CURRENT_SOURCE_DIR@' top_buildir='@abs_top_builddir@@CMAKE_CURRENT_SOURCE_DIR@' @@ -96,7 +94,7 @@ die () { mpirun () { # Set the name of the mpi launcher for use in test scripts. local mpi_launcher='@MPI_LAUNCHER@' - local oversubscribe='@OVERSUBSCRIBE@ --oversubscribe' + local oversubscribe='@OVERSUBSCRIBE@' # need to strip off any args that may be included with MPI_LAUNCHER arg for check below to work local mpi_cmd="`echo $mpi_launcher | awk '{print $1;}'`" # Check if running with MPI: if so, the mpi_launcher will point to a command From ea79a6626b50350d406e1753ccb7506c757cc64f Mon Sep 17 00:00:00 2001 From: rem1776 Date: Thu, 19 Feb 2026 12:05:37 -0500 Subject: [PATCH 10/30] revert changing the hostname command in the mpi launcher check --- configure.ac | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/configure.ac b/configure.ac index 0c4cc99ecf..0de0afe4d8 100644 --- a/configure.ac +++ b/configure.ac @@ -406,7 +406,7 @@ fi AC_CHECK_PROGS([MPI_LAUNCHER],[srun aprun mpirun]) # Check if the launcher can oversubscribe the MPI processes -AS_IF([$MPI_LAUNCHER --oversubscribe sh -c :], \ +AS_IF([$MPI_LAUNCHER --oversubscribe hostname], \ [ AC_SUBST([OVERSUBSCRIBE], [--oversubscribe])]) # Compiler with version information. This consists of the full path From bf20b6b1a913101bf5c8d8a040181f524be514a6 Mon Sep 17 00:00:00 2001 From: rem1776 Date: Wed, 4 Mar 2026 12:46:38 -0500 Subject: [PATCH 11/30] change mpi launcher command in configure and add separate check for new openmpi flag --- configure.ac | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/configure.ac b/configure.ac index 0de0afe4d8..4932b9b886 100644 --- a/configure.ac +++ b/configure.ac @@ -406,9 +406,13 @@ fi AC_CHECK_PROGS([MPI_LAUNCHER],[srun aprun mpirun]) # Check if the launcher can oversubscribe the MPI processes -AS_IF([$MPI_LAUNCHER --oversubscribe hostname], \ +AS_IF([$MPI_LAUNCHER --oversubscribe nproc >/dev/null 2>&1], \ [ AC_SUBST([OVERSUBSCRIBE], [--oversubscribe])]) +# newer openmpi versions take a different flag +AS_IF([$MPI_LAUNCHER --map-by :OVERSUBSCRIBE nproc >/dev/null 2>&1], \ + [ AC_SUBST([OVERSUBSCRIBE], [--map-by :OVERSUBSCRIBE])]) + # Compiler with version information. This consists of the full path # name of the compiler and the reported version number. AC_SUBST([CC_VERSION]) From de7b91a51d6875a6bbc2a1b99305c5d321465792 Mon Sep 17 00:00:00 2001 From: rem1776 Date: Wed, 4 Mar 2026 14:58:28 -0500 Subject: [PATCH 12/30] fix skipped tests variable for interpolator tests --- test_fms/interpolator/test_interpolator2.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test_fms/interpolator/test_interpolator2.sh b/test_fms/interpolator/test_interpolator2.sh index bd4cf7aab6..b43fd605c7 100755 --- a/test_fms/interpolator/test_interpolator2.sh +++ b/test_fms/interpolator/test_interpolator2.sh @@ -41,7 +41,7 @@ if test ! -z "$test_input_path" ; then rm -rf INPUT && mkdir INPUT cp $test_input_path/interpolator/INPUT/* INPUT else - SKIP_TESTS="$SKIP_TESTS $(basename $0 .sh).1" + SKIP_TESTS="$SKIP_TESTS test_interpolator2.1" fi # Create files for test. From 33dc00b34aa2f2ba8104fc537dfd8be9dcb91800 Mon Sep 17 00:00:00 2001 From: rem1776 Date: Wed, 4 Mar 2026 15:17:43 -0500 Subject: [PATCH 13/30] add checks for input files in interpolator test --- test_fms/interpolator/test_interpolator.F90 | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/test_fms/interpolator/test_interpolator.F90 b/test_fms/interpolator/test_interpolator.F90 index 5bc1dc1727..5597bf417d 100644 --- a/test_fms/interpolator/test_interpolator.F90 +++ b/test_fms/interpolator/test_interpolator.F90 @@ -260,7 +260,8 @@ subroutine sulfate_init(aerosol,lonb, latb, names, data_out_of_bounds, vert_inte type(FmsNetcdfFile_t) :: fileobj_aerosol filename_aerosol = "INPUT/aerosol.climatology.nc" -if (.not. open_file(fileobj_aerosol, filename_aerosol, "read") ) return +if (.not. open_file(fileobj_aerosol, filename_aerosol, "read") ) & + call mpp_error(FATAL, "aerosol.climatology.nc file not found, check --enable-test-input value when configuring") call interpolator_init( aerosol, "aerosol.climatology.nc", lonb, latb, & data_names=names, data_out_of_bounds=data_out_of_bounds, & vert_interp=vert_interp, clim_units=units ) @@ -296,7 +297,8 @@ subroutine ozone_init( o3, lonb, latb, axes, model_time, data_out_of_bounds, ver type(FmsNetcdfFile_t) :: fileobj_o3 filename_o3 = "INPUT/o3.climatology.nc" -if (.not. open_file(fileobj_o3, filename_o3, "read") ) return +if (.not. open_file(fileobj_o3, filename_o3, "read") ) & + call mpp_error(FATAL, "aerosol.climatology.nc file not found, check --enable-test-input value when configuring") call interpolator_init( o3, "o3.climatology.nc", lonb, latb, & data_out_of_bounds=data_out_of_bounds, vert_interp=vert_interp ) From 2694a80ca8c4064098e16fe85f9445edad368f75 Mon Sep 17 00:00:00 2001 From: rem1776 Date: Thu, 5 Mar 2026 15:06:38 -0500 Subject: [PATCH 14/30] add some missing end calls and do some debugging for interpolator input files --- test_fms/column_diagnostics/test_column_diagnostics.F90 | 3 ++- test_fms/interpolator/test_interpolator2.F90 | 4 +++- test_fms/interpolator/test_interpolator2.sh | 6 ++++++ 3 files changed, 11 insertions(+), 2 deletions(-) diff --git a/test_fms/column_diagnostics/test_column_diagnostics.F90 b/test_fms/column_diagnostics/test_column_diagnostics.F90 index 0dac6cc7bd..d71c91d308 100644 --- a/test_fms/column_diagnostics/test_column_diagnostics.F90 +++ b/test_fms/column_diagnostics/test_column_diagnostics.F90 @@ -25,7 +25,7 @@ program test_column_diagnostics use column_diagnostics_mod - use fms_mod, only: fms_init + use fms_mod, only: fms_init, fms_end use mpp_mod, only: FATAL, mpp_error use time_manager_mod, only: time_manager_init, time_type, set_time, set_calendar_type use constants_mod, only : PI, DEG_TO_RAD @@ -62,6 +62,7 @@ program test_column_diagnostics call initialize_variables(0.01_lkind) !< set up input arrays; call test_initialize_diagnostic_columns !< initialize diagnostics column call test_column_diagnostics_header + call fms_end() contains !------------------------------------------! diff --git a/test_fms/interpolator/test_interpolator2.F90 b/test_fms/interpolator/test_interpolator2.F90 index 8170a6fa68..1cf450dd1b 100644 --- a/test_fms/interpolator/test_interpolator2.F90 +++ b/test_fms/interpolator/test_interpolator2.F90 @@ -36,7 +36,7 @@ program test_interpolator2 set_date_no_leap, set_date_julian, operator(/), & operator(+), operator(-), time_type_to_real, increment_time, & leap_year, days_in_month, print_date, print_time - use fms_mod, only: fms_init + use fms_mod, only: fms_init, fms_end use constants_mod, only: PI use platform_mod, only: r4_kind, r8_kind use fms_test_mod, only: permutable_indices_2d, permutable_indices_3d, permutable_indices_4d, factorial, & @@ -124,6 +124,8 @@ program test_interpolator2 call test_interpolator_end(o3) end if + call fms_end() + contains #include "test_interpolator_write_climatology.inc" diff --git a/test_fms/interpolator/test_interpolator2.sh b/test_fms/interpolator/test_interpolator2.sh index b43fd605c7..d360eee8b6 100755 --- a/test_fms/interpolator/test_interpolator2.sh +++ b/test_fms/interpolator/test_interpolator2.sh @@ -61,7 +61,13 @@ cat <<_EOF > input.nml / _EOF +set -x + # Run test +echo "asdf input dir: $test_input_path" +ls $test_input_path +ls $test_input_path/* +ls INPUT test_expect_success "test interpolator" 'mpirun -n 1 ./test_interpolator' From 214bbd921ed8869c8932fe7dadac42dcac3fa02c Mon Sep 17 00:00:00 2001 From: Ryan Mulhall <35538242+rem1776@users.noreply.github.com> Date: Wed, 11 Mar 2026 15:56:47 -0400 Subject: [PATCH 15/30] skip time_interp test in autotools ci --- .github/workflows/github_autotools_gnu.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/github_autotools_gnu.yml b/.github/workflows/github_autotools_gnu.yml index 739b5fd865..4ce5ffa15a 100644 --- a/.github/workflows/github_autotools_gnu.yml +++ b/.github/workflows/github_autotools_gnu.yml @@ -21,8 +21,9 @@ jobs: image: ghcr.io/noaa-gfdl/fms-gnu-ci:15.2.1 env: TEST_VERBOSE: 1 - DISTCHECK_CONFIGURE_FLAGS: "${{ matrix.conf-flag }} ${{ matrix.input-flag }} ${{ matrix.io-flag }}" + DISTCHECK_CONFIGURE_FLAGS: "${{ matrix.conf-flag }} ${{ matrix.input-flag }}" DEBUG_FLAGS: "-O0 -g -fbounds-check -ffpe-trap=invalid,zero,overflow" # debug compiler flags taken from the mkmf template + SKIP_TESTS: "test_time_interp2.7" steps: - name: Checkout code uses: actions/checkout@v6.0.1 From 8af5c1558465a6acbdfdd2a0a7b85608da013ed0 Mon Sep 17 00:00:00 2001 From: Ryan Mulhall <35538242+rem1776@users.noreply.github.com> Date: Thu, 12 Mar 2026 10:38:24 -0400 Subject: [PATCH 16/30] Add test_time_interp2.8 to SKIP_TESTS --- .github/workflows/github_autotools_gnu.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/github_autotools_gnu.yml b/.github/workflows/github_autotools_gnu.yml index 4ce5ffa15a..f68657dcd7 100644 --- a/.github/workflows/github_autotools_gnu.yml +++ b/.github/workflows/github_autotools_gnu.yml @@ -23,7 +23,7 @@ jobs: TEST_VERBOSE: 1 DISTCHECK_CONFIGURE_FLAGS: "${{ matrix.conf-flag }} ${{ matrix.input-flag }}" DEBUG_FLAGS: "-O0 -g -fbounds-check -ffpe-trap=invalid,zero,overflow" # debug compiler flags taken from the mkmf template - SKIP_TESTS: "test_time_interp2.7" + SKIP_TESTS: "test_time_interp2.7 test_time_interp2.8" # TODO, these tests pass occasionally, but usually fail opening input steps: - name: Checkout code uses: actions/checkout@v6.0.1 From 9db2a15f7dc929afc632cdb2e9e30f71b99d8d60 Mon Sep 17 00:00:00 2001 From: rem1776 Date: Thu, 12 Mar 2026 11:56:08 -0400 Subject: [PATCH 17/30] revert debugging changes --- .github/workflows/github_autotools_gnu.yml | 3 +-- test_fms/interpolator/test_interpolator.F90 | 6 ++---- test_fms/interpolator/test_interpolator2.sh | 6 ------ 3 files changed, 3 insertions(+), 12 deletions(-) diff --git a/.github/workflows/github_autotools_gnu.yml b/.github/workflows/github_autotools_gnu.yml index f68657dcd7..98f5f6bedf 100644 --- a/.github/workflows/github_autotools_gnu.yml +++ b/.github/workflows/github_autotools_gnu.yml @@ -30,10 +30,9 @@ jobs: - name: Prepare GNU autoconf for build run: autoreconf -if - name: Configure the build - if: ${{ matrix.conf-flag != '--disable-setting-flags' }} run: ./configure ${DISTCHECK_CONFIGURE_FLAGS} FCFLAGS="$FCFLAGS $DEBUG_FLAGS" - name: Run distcheck (compiles, tests, and packages) - run: make -k distcheck + run: make distcheck if: ${{ matrix.conf-flag != '--with-mpi=no' }} - name: Build the library (without test suite for serial build) run: make diff --git a/test_fms/interpolator/test_interpolator.F90 b/test_fms/interpolator/test_interpolator.F90 index 5597bf417d..5bc1dc1727 100644 --- a/test_fms/interpolator/test_interpolator.F90 +++ b/test_fms/interpolator/test_interpolator.F90 @@ -260,8 +260,7 @@ subroutine sulfate_init(aerosol,lonb, latb, names, data_out_of_bounds, vert_inte type(FmsNetcdfFile_t) :: fileobj_aerosol filename_aerosol = "INPUT/aerosol.climatology.nc" -if (.not. open_file(fileobj_aerosol, filename_aerosol, "read") ) & - call mpp_error(FATAL, "aerosol.climatology.nc file not found, check --enable-test-input value when configuring") +if (.not. open_file(fileobj_aerosol, filename_aerosol, "read") ) return call interpolator_init( aerosol, "aerosol.climatology.nc", lonb, latb, & data_names=names, data_out_of_bounds=data_out_of_bounds, & vert_interp=vert_interp, clim_units=units ) @@ -297,8 +296,7 @@ subroutine ozone_init( o3, lonb, latb, axes, model_time, data_out_of_bounds, ver type(FmsNetcdfFile_t) :: fileobj_o3 filename_o3 = "INPUT/o3.climatology.nc" -if (.not. open_file(fileobj_o3, filename_o3, "read") ) & - call mpp_error(FATAL, "aerosol.climatology.nc file not found, check --enable-test-input value when configuring") +if (.not. open_file(fileobj_o3, filename_o3, "read") ) return call interpolator_init( o3, "o3.climatology.nc", lonb, latb, & data_out_of_bounds=data_out_of_bounds, vert_interp=vert_interp ) diff --git a/test_fms/interpolator/test_interpolator2.sh b/test_fms/interpolator/test_interpolator2.sh index d360eee8b6..b43fd605c7 100755 --- a/test_fms/interpolator/test_interpolator2.sh +++ b/test_fms/interpolator/test_interpolator2.sh @@ -61,13 +61,7 @@ cat <<_EOF > input.nml / _EOF -set -x - # Run test -echo "asdf input dir: $test_input_path" -ls $test_input_path -ls $test_input_path/* -ls INPUT test_expect_success "test interpolator" 'mpirun -n 1 ./test_interpolator' From 829694c742a2766c6f81044e3e682ee4063047d1 Mon Sep 17 00:00:00 2001 From: rem1776 Date: Thu, 12 Mar 2026 16:58:18 -0400 Subject: [PATCH 18/30] add cmake support for openmpi alternative oversubscribe flag --- .github/workflows/github_autotools_gnu.yml | 3 ++- CMakeLists.txt | 21 +++++++++++++++++++++ 2 files changed, 23 insertions(+), 1 deletion(-) diff --git a/.github/workflows/github_autotools_gnu.yml b/.github/workflows/github_autotools_gnu.yml index 98f5f6bedf..e51a982b8d 100644 --- a/.github/workflows/github_autotools_gnu.yml +++ b/.github/workflows/github_autotools_gnu.yml @@ -23,7 +23,8 @@ jobs: TEST_VERBOSE: 1 DISTCHECK_CONFIGURE_FLAGS: "${{ matrix.conf-flag }} ${{ matrix.input-flag }}" DEBUG_FLAGS: "-O0 -g -fbounds-check -ffpe-trap=invalid,zero,overflow" # debug compiler flags taken from the mkmf template - SKIP_TESTS: "test_time_interp2.7 test_time_interp2.8" # TODO, these tests pass occasionally, but usually fail opening input + # tests to skip in CI testing, skips all the openmp + logical mask tests for the diag_manager due to issues with gcc + SKIP_TESTS: "test_time_none.10 test_time_sum.10 test_time_avg.10 test_time_min.10 test_time_max.10 test_time_pow.10 test_time_rms.10" steps: - name: Checkout code uses: actions/checkout@v6.0.1 diff --git a/CMakeLists.txt b/CMakeLists.txt index 011a2d23af..c219bf5d3a 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -97,6 +97,21 @@ if (WITH_YAML) pkg_check_modules(YAML REQUIRED IMPORTED_TARGET "yaml-0.1") endif () +# TODO should be better ways to find mpi vendor, this is just checking the path +if(MPI_Fortran_FOUND) + message(STATUS "MPI Version String: ${MPI_Fortran_COMPILER}") + if(MPI_Fortran_COMPILER MATCHES "openmpi") + set(MPI_VENDOR "OpenMPI") + elseif(MPI_Fortran_COMPILER MATCHES "mpich") + set(MPI_VENDOR "MPICH") + elseif(MPI_Fortran_COMPILER MATCHES "oneapi") + set(MPI_VENDOR "Intel") + else() + set(MPI_VENDOR "Unknown") + endif() + message(STATUS "Detected MPI Vendor: ${MPI_VENDOR}") +endif() + # Enables position independent code (i.e., -fPIC) if (FPIC) set(CMAKE_POSITION_INDEPENDENT_CODE ON) @@ -594,6 +609,12 @@ include(CTest) set(MPI_LAUNCHER "mpirun") # used in the test-lib.sh.in to make it behave differently when parsed by cmake set(USING_CMAKE "true") +# set the right oversubscribe flag +if(MPI_VENDOR MATCHES "OpenMPI") + set(OVERSUBSCRIBE "--map-by :OVERSUBSCRIBE") +else() + set(OVERSUBSCRIBE "--oversubscribe") +endif() # parse and add build info to test script util file configure_file(${CMAKE_CURRENT_SOURCE_DIR}/test_fms/test-lib.sh.in ${CMAKE_CURRENT_SOURCE_DIR}/test-lib.sh From 98b85e6598239e1e3a1af107d09a227430b02f33 Mon Sep 17 00:00:00 2001 From: Ryan Mulhall <35538242+rem1776@users.noreply.github.com> Date: Thu, 12 Mar 2026 17:29:49 -0400 Subject: [PATCH 19/30] skip expected fail test from mpp, reduce output to just failures --- .github/workflows/github_autotools_gnu.yml | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/.github/workflows/github_autotools_gnu.yml b/.github/workflows/github_autotools_gnu.yml index e51a982b8d..7cc1816403 100644 --- a/.github/workflows/github_autotools_gnu.yml +++ b/.github/workflows/github_autotools_gnu.yml @@ -20,11 +20,11 @@ jobs: container: image: ghcr.io/noaa-gfdl/fms-gnu-ci:15.2.1 env: - TEST_VERBOSE: 1 DISTCHECK_CONFIGURE_FLAGS: "${{ matrix.conf-flag }} ${{ matrix.input-flag }}" DEBUG_FLAGS: "-O0 -g -fbounds-check -ffpe-trap=invalid,zero,overflow" # debug compiler flags taken from the mkmf template - # tests to skip in CI testing, skips all the openmp + logical mask tests for the diag_manager due to issues with gcc - SKIP_TESTS: "test_time_none.10 test_time_sum.10 test_time_avg.10 test_time_min.10 test_time_max.10 test_time_pow.10 test_time_rms.10" + # diag manager openmp + logical mask tests fail with gcc, these are reproducible outside the CI + # test_mpp_clock_begin_end_id is an expected fail that is passing, does not seem to show up outside CI + SKIP_TESTS: "test_time_none.10 test_time_sum.10 test_time_avg.10 test_time_min.10 test_time_max.10 test_time_pow.10 test_time_rms.10 test_mpp_clock_begin_end_id.10" steps: - name: Checkout code uses: actions/checkout@v6.0.1 @@ -33,7 +33,9 @@ jobs: - name: Configure the build run: ./configure ${DISTCHECK_CONFIGURE_FLAGS} FCFLAGS="$FCFLAGS $DEBUG_FLAGS" - name: Run distcheck (compiles, tests, and packages) - run: make distcheck + run: | + make distcheck 2>&1 > distcheck.log + grep -E "^FAIL:|^XPASS:" distcheck.log if: ${{ matrix.conf-flag != '--with-mpi=no' }} - name: Build the library (without test suite for serial build) run: make From 506fb1930485bbcdd7f62e421b55281635982e3a Mon Sep 17 00:00:00 2001 From: Ryan Mulhall <35538242+rem1776@users.noreply.github.com> Date: Fri, 13 Mar 2026 11:46:40 -0400 Subject: [PATCH 20/30] add step to upload distcheck log on failure Added log upload step for distcheck failures. --- .github/workflows/github_autotools_gnu.yml | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/.github/workflows/github_autotools_gnu.yml b/.github/workflows/github_autotools_gnu.yml index 7cc1816403..a770f74a58 100644 --- a/.github/workflows/github_autotools_gnu.yml +++ b/.github/workflows/github_autotools_gnu.yml @@ -33,10 +33,13 @@ jobs: - name: Configure the build run: ./configure ${DISTCHECK_CONFIGURE_FLAGS} FCFLAGS="$FCFLAGS $DEBUG_FLAGS" - name: Run distcheck (compiles, tests, and packages) - run: | - make distcheck 2>&1 > distcheck.log - grep -E "^FAIL:|^XPASS:" distcheck.log + run: make distcheck 2>&1 > distcheck.log if: ${{ matrix.conf-flag != '--with-mpi=no' }} + - name: Upload log on failure + uses: actions/upload-artifact@v7.0.0 + if: failure() + with: + path: distcheck.log - name: Build the library (without test suite for serial build) run: make if: ${{ matrix.conf-flag == '--with-mpi=no' }} From 72280c7e04dc1d7dd3a5d06f1a9f70797610676b Mon Sep 17 00:00:00 2001 From: Ryan Mulhall <35538242+rem1776@users.noreply.github.com> Date: Fri, 13 Mar 2026 12:36:23 -0400 Subject: [PATCH 21/30] skip time_interp test due to file issues --- .github/workflows/github_autotools_gnu.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/github_autotools_gnu.yml b/.github/workflows/github_autotools_gnu.yml index a770f74a58..6fb4e5bed6 100644 --- a/.github/workflows/github_autotools_gnu.yml +++ b/.github/workflows/github_autotools_gnu.yml @@ -23,8 +23,9 @@ jobs: DISTCHECK_CONFIGURE_FLAGS: "${{ matrix.conf-flag }} ${{ matrix.input-flag }}" DEBUG_FLAGS: "-O0 -g -fbounds-check -ffpe-trap=invalid,zero,overflow" # debug compiler flags taken from the mkmf template # diag manager openmp + logical mask tests fail with gcc, these are reproducible outside the CI - # test_mpp_clock_begin_end_id is an expected fail that is passing, does not seem to show up outside CI - SKIP_TESTS: "test_time_none.10 test_time_sum.10 test_time_avg.10 test_time_min.10 test_time_max.10 test_time_pow.10 test_time_rms.10 test_mpp_clock_begin_end_id.10" + # test_mpp_clock_begin_end_id is an expected fail that is passing, only happens in the CI + # test_time_interp2 tests fail from file issues, only happens in the CI + SKIP_TESTS: "test_time_none.10 test_time_sum.10 test_time_avg.10 test_time_min.10 test_time_max.10 test_time_pow.10 test_time_rms.10 test_mpp_clock_begin_end_id.10 test_time_interp2.7 test_time_interp2.8" steps: - name: Checkout code uses: actions/checkout@v6.0.1 From df5c9d7b176a66e6a63960bcb7a59a504dcca7ab Mon Sep 17 00:00:00 2001 From: rem1776 Date: Wed, 18 Mar 2026 10:27:50 -0500 Subject: [PATCH 22/30] remove some older test failures for cmake build, switch mom6 image and use internal action for deps --- .github/workflows/github_cmake_gnu.yml | 4 ++-- .github/workflows/github_mom_gnu.yml | 7 ++----- 2 files changed, 4 insertions(+), 7 deletions(-) diff --git a/.github/workflows/github_cmake_gnu.yml b/.github/workflows/github_cmake_gnu.yml index 86f0f2881e..9b5176b4b8 100644 --- a/.github/workflows/github_cmake_gnu.yml +++ b/.github/workflows/github_cmake_gnu.yml @@ -18,7 +18,7 @@ jobs: image: ghcr.io/noaa-gfdl/fms-gnu-ci:15.2.1 env: CMAKE_FLAGS: "${{ matrix.build-type }} ${{ matrix.libyaml-flag }}" - EXCLUDE_TESTS: "test_mpp_nesting|test_bc_restart|test_collective_io|test_fms2_io|test_io_with_mask" + EXCLUDE_TESTS: "test_mpp_nesting|test_mpp_clock_begin_end_id" PKG_CONFIG_PATH: "/opt/views/view/lib64/pkgconfig:/opt/views/view/lib/pkgconfig:/opt/views/view/share/pkgconfig" steps: - name: Checkout code @@ -43,7 +43,7 @@ jobs: image: ghcr.io/noaa-gfdl/fms/fms-ci-rocky-gnu:13.2.0-arm env: CMAKE_FLAGS: "${{ matrix.build-type }} ${{ matrix.libyaml-flag }}" - EXCLUDE_TESTS: "test_mpp_nesting|test_bc_restart|test_collective_io|test_fms2_io|test_io_with_mask|test_sat_vapor_pres" + EXCLUDE_TESTS: "test_mpp_nesting|test_sat_vapor_pres|test_mpp_clock_begin_end_id" PKG_CONFIG_PATH: "/opt/views/view/lib64/pkgconfig:/opt/views/view/lib/pkgconfig:/opt/views/view/share/pkgconfig" steps: - name: Checkout code diff --git a/.github/workflows/github_mom_gnu.yml b/.github/workflows/github_mom_gnu.yml index aae652f42a..b534d82fcc 100644 --- a/.github/workflows/github_mom_gnu.yml +++ b/.github/workflows/github_mom_gnu.yml @@ -11,17 +11,14 @@ concurrency: jobs: build: runs-on: ubuntu-latest - container: - image: ghcr.io/noaa-gfdl/fms-gnu-ci:15.2.1 - credentials: - username: ${{ github.actor }} - password: ${{ secrets.github_token }} steps: - name: Checkout MOM6 repository uses: actions/checkout@v4.2.2 with: repository: 'NOAA-GFDL/MOM6' submodules: recursive + - name: Install dependency packages + uses: ./.github/actions/ubuntu-setup/ - name: Checkout FMS into MOM build uses: actions/checkout@v4.2.2 with: From ea12111addbcdfa91a526a6418ac8e3c6fbca78c Mon Sep 17 00:00:00 2001 From: rem1776 Date: Wed, 18 Mar 2026 13:41:50 -0500 Subject: [PATCH 23/30] change cmake oversubscribe flag to a build option instead of dynamically setting --- .github/workflows/github_cmake_gnu.yml | 4 ++-- CMakeLists.txt | 27 ++++++-------------------- 2 files changed, 8 insertions(+), 23 deletions(-) diff --git a/.github/workflows/github_cmake_gnu.yml b/.github/workflows/github_cmake_gnu.yml index 9b5176b4b8..99c4d95fd2 100644 --- a/.github/workflows/github_cmake_gnu.yml +++ b/.github/workflows/github_cmake_gnu.yml @@ -18,7 +18,7 @@ jobs: image: ghcr.io/noaa-gfdl/fms-gnu-ci:15.2.1 env: CMAKE_FLAGS: "${{ matrix.build-type }} ${{ matrix.libyaml-flag }}" - EXCLUDE_TESTS: "test_mpp_nesting|test_mpp_clock_begin_end_id" + EXCLUDE_TESTS: "test_mpp_nesting|test_mpp_clock_begin_end_id|test_time_*" PKG_CONFIG_PATH: "/opt/views/view/lib64/pkgconfig:/opt/views/view/lib/pkgconfig:/opt/views/view/share/pkgconfig" steps: - name: Checkout code @@ -27,7 +27,7 @@ jobs: run: | mkdir build cd build - cmake $CMAKE_FLAGS -DOPENMP=on -DNetCDF_ROOT=/opt/view -DLIBYAML_ROOT=/opt/view .. + cmake -DOVERSUBSCRIBE_FLAG="--map-by :OVERSUBSCRIBE" $CMAKE_FLAGS -DOPENMP=on -DNetCDF_ROOT=/opt/view -DLIBYAML_ROOT=/opt/view .. - name: Build the library run: make -C build - name: Run the unit tests diff --git a/CMakeLists.txt b/CMakeLists.txt index 9668ff15e2..a9c45374fb 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -64,6 +64,9 @@ option(PORTABLE_KINDS "Enable compiler definition -DPORTABLE_KINDS" option(GFS_PHYS "Enable compiler definition -DGFS_PHYS" OFF) option(WITH_YAML "Enable compiler definition -Duse_yaml" OFF) +# Testing-specific options +set(OVERSUBSCRIBE_FLAG "--oversubscribe" CACHE STRING "Flag for mpirun to use more cores than available") + if(32BIT) list(APPEND kinds "r4") message(STATUS "Building library with 4-byte real defaults (with mixed precision real support for most modules).") @@ -94,21 +97,6 @@ if (WITH_YAML) pkg_check_modules(YAML REQUIRED IMPORTED_TARGET "yaml-0.1") endif () -# TODO should be better ways to find mpi vendor, this is just checking the path -if(MPI_Fortran_FOUND) - message(STATUS "MPI Version String: ${MPI_Fortran_COMPILER}") - if(MPI_Fortran_COMPILER MATCHES "openmpi") - set(MPI_VENDOR "OpenMPI") - elseif(MPI_Fortran_COMPILER MATCHES "mpich") - set(MPI_VENDOR "MPICH") - elseif(MPI_Fortran_COMPILER MATCHES "oneapi") - set(MPI_VENDOR "Intel") - else() - set(MPI_VENDOR "Unknown") - endif() - message(STATUS "Detected MPI Vendor: ${MPI_VENDOR}") -endif() - # Enables position independent code (i.e., -fPIC) if (FPIC) set(CMAKE_POSITION_INDEPENDENT_CODE ON) @@ -599,12 +587,9 @@ include(CTest) set(MPI_LAUNCHER "mpirun") # used in the test-lib.sh.in to make it behave differently when parsed by cmake set(USING_CMAKE "true") -# set the right oversubscribe flag -if(MPI_VENDOR MATCHES "OpenMPI") - set(OVERSUBSCRIBE "--map-by :OVERSUBSCRIBE") -else() - set(OVERSUBSCRIBE "--oversubscribe") - endif() +set(OVERSUBSCRIBE "${OVERSUBSCRIBE_FLAG}") +message(STATUS "Using '${OVERSUBSCRIBE}' flag to oversubscribe ranks in test scripts") + # set the fms library to link tests with based on whats built if(NOT kinds) set(fmsLibraryName FMS::fms) From 6a9ae729dc301f4359097cd8279674a736517460 Mon Sep 17 00:00:00 2001 From: Ryan Mulhall <35538242+rem1776@users.noreply.github.com> Date: Thu, 19 Mar 2026 15:17:49 -0500 Subject: [PATCH 24/30] Try adding some spaces to the flag --- CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index a9c45374fb..b1666b5790 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -65,7 +65,7 @@ option(GFS_PHYS "Enable compiler definition -DGFS_PHYS" option(WITH_YAML "Enable compiler definition -Duse_yaml" OFF) # Testing-specific options -set(OVERSUBSCRIBE_FLAG "--oversubscribe" CACHE STRING "Flag for mpirun to use more cores than available") +set(OVERSUBSCRIBE_FLAG " --oversubscribe " CACHE STRING "Flag for mpirun to use more cores than available") if(32BIT) list(APPEND kinds "r4") From d62dd92d9e62cbefda11bd8c28ecc13d8bb899c1 Mon Sep 17 00:00:00 2001 From: Ryan Mulhall <35538242+rem1776@users.noreply.github.com> Date: Thu, 19 Mar 2026 16:07:49 -0500 Subject: [PATCH 25/30] Add debug output to mpirun function --- test_fms/test-lib.sh.in | 1 + 1 file changed, 1 insertion(+) diff --git a/test_fms/test-lib.sh.in b/test_fms/test-lib.sh.in index 5f92ad7639..b56af1eff7 100644 --- a/test_fms/test-lib.sh.in +++ b/test_fms/test-lib.sh.in @@ -92,6 +92,7 @@ die () { # Possibly wrapping the mpirun command. mpirun () { + set -x # Set the name of the mpi launcher for use in test scripts. local mpi_launcher='@MPI_LAUNCHER@' local oversubscribe='@OVERSUBSCRIBE@' From f49277d8bcf84d63ce30a7035e9841c09a6acbd4 Mon Sep 17 00:00:00 2001 From: rem1776 Date: Tue, 31 Mar 2026 16:50:22 -0400 Subject: [PATCH 26/30] update to new spack-based image --- .github/workflows/github_autotools_gnu.yml | 2 +- .github/workflows/github_cmake_gnu.yml | 2 +- .github/workflows/github_coupler_gnu.yml | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/github_autotools_gnu.yml b/.github/workflows/github_autotools_gnu.yml index 6fb4e5bed6..2afef10399 100644 --- a/.github/workflows/github_autotools_gnu.yml +++ b/.github/workflows/github_autotools_gnu.yml @@ -18,7 +18,7 @@ jobs: - conf-flag: --with-mpi=no input-flag: --enable-test-input=/home/unit_tests_input container: - image: ghcr.io/noaa-gfdl/fms-gnu-ci:15.2.1 + image: ghcr.io/noaa-gfdl/fms/fms-ci-rocky-gnu:15.1.0 env: DISTCHECK_CONFIGURE_FLAGS: "${{ matrix.conf-flag }} ${{ matrix.input-flag }}" DEBUG_FLAGS: "-O0 -g -fbounds-check -ffpe-trap=invalid,zero,overflow" # debug compiler flags taken from the mkmf template diff --git a/.github/workflows/github_cmake_gnu.yml b/.github/workflows/github_cmake_gnu.yml index 99c4d95fd2..1306e1379b 100644 --- a/.github/workflows/github_cmake_gnu.yml +++ b/.github/workflows/github_cmake_gnu.yml @@ -15,7 +15,7 @@ jobs: libyaml-flag: [ "", -DWITH_YAML=on ] build-type: [ "-DCMAKE_BUILD_TYPE=Release", "-DCMAKE_BUILD_TYPE=Debug" ] container: - image: ghcr.io/noaa-gfdl/fms-gnu-ci:15.2.1 + image: ghcr.io/noaa-gfdl/fms/fms-ci-rocky-gnu:15.1.0 env: CMAKE_FLAGS: "${{ matrix.build-type }} ${{ matrix.libyaml-flag }}" EXCLUDE_TESTS: "test_mpp_nesting|test_mpp_clock_begin_end_id|test_time_*" diff --git a/.github/workflows/github_coupler_gnu.yml b/.github/workflows/github_coupler_gnu.yml index 9552f01959..daf5139a54 100644 --- a/.github/workflows/github_coupler_gnu.yml +++ b/.github/workflows/github_coupler_gnu.yml @@ -10,7 +10,7 @@ jobs: coupler-build: runs-on: ubuntu-latest container: - image: ghcr.io/noaa-gfdl/fms-gnu-ci:15.2.1 + image: ghcr.io/noaa-gfdl/fms/fms-ci-rocky-gnu:15.1.0 credentials: username: ${{ github.actor }} password: ${{ secrets.github_token }} From 1428a1d6e9e8b5c73378f1f85f51cd16fbc44141 Mon Sep 17 00:00:00 2001 From: rem1776 Date: Tue, 31 Mar 2026 17:15:37 -0400 Subject: [PATCH 27/30] add output for configure script if failed --- .github/workflows/github_autotools_gnu.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/github_autotools_gnu.yml b/.github/workflows/github_autotools_gnu.yml index 2afef10399..a0802f9912 100644 --- a/.github/workflows/github_autotools_gnu.yml +++ b/.github/workflows/github_autotools_gnu.yml @@ -32,7 +32,7 @@ jobs: - name: Prepare GNU autoconf for build run: autoreconf -if - name: Configure the build - run: ./configure ${DISTCHECK_CONFIGURE_FLAGS} FCFLAGS="$FCFLAGS $DEBUG_FLAGS" + run: ./configure ${DISTCHECK_CONFIGURE_FLAGS} FCFLAGS="$FCFLAGS $DEBUG_FLAGS" || cat config.log - name: Run distcheck (compiles, tests, and packages) run: make distcheck 2>&1 > distcheck.log if: ${{ matrix.conf-flag != '--with-mpi=no' }} From 950fdaf8fc3780b7cc98d423972ef5b1f7ab22ee Mon Sep 17 00:00:00 2001 From: rem1776 Date: Wed, 1 Apr 2026 11:04:24 -0400 Subject: [PATCH 28/30] remove debug option, add output error step --- .github/workflows/github_autotools_gnu.yml | 3 +++ test_fms/test-lib.sh.in | 12 +++--------- 2 files changed, 6 insertions(+), 9 deletions(-) diff --git a/.github/workflows/github_autotools_gnu.yml b/.github/workflows/github_autotools_gnu.yml index a0802f9912..b17dd4be6f 100644 --- a/.github/workflows/github_autotools_gnu.yml +++ b/.github/workflows/github_autotools_gnu.yml @@ -36,6 +36,9 @@ jobs: - name: Run distcheck (compiles, tests, and packages) run: make distcheck 2>&1 > distcheck.log if: ${{ matrix.conf-flag != '--with-mpi=no' }} + - name: Output errors on failure + run: grep -E "^FAIL:|^XPASS:" distcheck.log + if: failure() - name: Upload log on failure uses: actions/upload-artifact@v7.0.0 if: failure() diff --git a/test_fms/test-lib.sh.in b/test_fms/test-lib.sh.in index b56af1eff7..e5451dd2d2 100644 --- a/test_fms/test-lib.sh.in +++ b/test_fms/test-lib.sh.in @@ -32,14 +32,9 @@ TEST_NAME="$(basename "$0" .sh)" TEST_NUMBER="${TEST_NAME%%-*}" TEST_NUMBER="${TEST_NUMBER#t}" -exec 7>&2 -# For now, write all output -#if test -n "$VERBOSE" -#then - exec 4>&2 3>&1 -#else -# exec 4>/dev/null 3>/dev/null -#fi +# redirects for stdout/stderr +# used to control output from this script and each test +exec 4>&2 3>&1 7>&2 test_count=0 test_success=0 @@ -92,7 +87,6 @@ die () { # Possibly wrapping the mpirun command. mpirun () { - set -x # Set the name of the mpi launcher for use in test scripts. local mpi_launcher='@MPI_LAUNCHER@' local oversubscribe='@OVERSUBSCRIBE@' From 06acd345a91570e0453f1570663a5bc88b760b79 Mon Sep 17 00:00:00 2001 From: Ryan Mulhall <35538242+rem1776@users.noreply.github.com> Date: Thu, 9 Apr 2026 16:03:02 -0400 Subject: [PATCH 29/30] update arm image for new cmake version --- .github/workflows/github_cmake_gnu.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/github_cmake_gnu.yml b/.github/workflows/github_cmake_gnu.yml index 864e0586a7..f0a9a3e57f 100644 --- a/.github/workflows/github_cmake_gnu.yml +++ b/.github/workflows/github_cmake_gnu.yml @@ -40,7 +40,7 @@ jobs: libyaml-flag: [ "", -DWITH_YAML=on ] build-type: [ "-DCMAKE_BUILD_TYPE=Release", "-DCMAKE_BUILD_TYPE=Debug" ] container: - image: ghcr.io/noaa-gfdl/fms/fms-ci-rocky-gnu:13.2.0-arm + image: ghcr.io/noaa-gfdl/fms/fms-ci-rocky-gnu:13.2.0-arm-cmake-update env: CMAKE_FLAGS: "${{ matrix.build-type }} ${{ matrix.libyaml-flag }}" EXCLUDE_TESTS: "test_mpp_nesting|test_sat_vapor_pres|test_mpp_clock_begin_end_id" From 6e791fae81480218d43f1f27c6ecdfcc607b88de Mon Sep 17 00:00:00 2001 From: Ryan Mulhall <35538242+rem1776@users.noreply.github.com> Date: Thu, 9 Apr 2026 16:28:49 -0400 Subject: [PATCH 30/30] use no oversubscribe flag for the arm test --- .github/workflows/github_cmake_gnu.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/github_cmake_gnu.yml b/.github/workflows/github_cmake_gnu.yml index f0a9a3e57f..4487818584 100644 --- a/.github/workflows/github_cmake_gnu.yml +++ b/.github/workflows/github_cmake_gnu.yml @@ -52,7 +52,7 @@ jobs: run: | mkdir build cd build - cmake $CMAKE_FLAGS -DOPENMP=on -DUNIT_TESTS=on -DNetCDF_ROOT=/opt/view -DLIBYAML_ROOT=/opt/view .. + cmake $CMAKE_FLAGS -DOVERSUBSCRIBE_FLAG="" -DOPENMP=on -DUNIT_TESTS=on -DNetCDF_ROOT=/opt/view -DLIBYAML_ROOT=/opt/view .. - name: Build the library run: make -C build - name: Run the unit tests