diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index ee12ff7f..431ec4e8 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -6,7 +6,7 @@ jobs: build: runs-on: ubuntu-latest container: - image: underwoo/ubuntu_libfms_gnu + image: noaagfdl/hpc-me.ubuntu-minimal:coupler env: CC: mpicc FC: mpif90 diff --git a/simple/ice_model.F90 b/simple/ice_model.F90 index c469abaa..02802dbe 100644 --- a/simple/ice_model.F90 +++ b/simple/ice_model.F90 @@ -524,6 +524,11 @@ subroutine ice_model_init ( Ice, Time_Init, Time, & !enddo !enddo + ! set io domain if not there in order to check files + if ( .not. associated(mpp_get_io_domain(Ice%domain)) ) then + call mpp_define_io_domain(Ice%domain, (/ 1, 1 /) ) + endif + ! read the land mask from a file (land=1) if (open_file(land_mask_fileobj, 'INPUT/land_mask.nc', 'read', Ice%domain)) then call read_data (land_mask_fileobj, 'land_mask', Ice%glon) diff --git a/t/null_model_build.sh b/t/null_model_build.sh index 4d6aa73f..7e2d6b57 100755 --- a/t/null_model_build.sh +++ b/t/null_model_build.sh @@ -24,7 +24,12 @@ export PATH=${PATH}:${bld_dir}/mkmf/bin mk_template=${bld_dir}/mkmf/templates/linux-ubuntu-xenial-gnu.mk # FMS -git clone https://github.com/NOAA-GFDL/FMS.git $src_dir/FMS +if [ "$1" = "--local-fms" ]; then + test -d "../../../FMS" || echo "Error: --local-fms specified but FMS src not found in parent directory" 1>&2 + cp -r ../../../FMS $src_dir/FMS +else + git clone https://github.com/NOAA-GFDL/FMS.git $src_dir/FMS +fi # ocean_null git clone https://github.com/NOAA-GFDL/ocean_null.git $src_dir/ocean_null @@ -94,7 +99,7 @@ EOF mkdir -p $bld_dir/fms list_paths -o $bld_dir/fms/pathnames_fms $src_dir/FMS cd $bld_dir/fms -mkmf -m Makefile -a $src_dir -b $bld_dir -p libfms.a -t $mkmf_template -g -c "-Duse_netCDF -Duse_libMPI -DMAXFIELDS_=200 -DMAXFIELDMETHODS_=200 -DINTERNAL_FILE_NML" -IFMS/include -IFMS/mpp/include $bld_dir/fms/pathnames_fms +mkmf -m Makefile -a $src_dir -b $bld_dir -p libfms.a -t $mkmf_template -g -c "-Duse_netCDF -Duse_libMPI -DMAXFIELDS_=200 -DMAXFIELDMETHODS_=200 -DINTERNAL_FILE_NML -DHAVE_GETTID" -IFMS/include -IFMS/mpp/include $bld_dir/fms/pathnames_fms cd $bld_dir # libocean_null @@ -152,9 +157,9 @@ make -j NETCDF=3 DEBUG=on coupler_full_test.x # Report on the status of the build if [ $? -eq 0 ] then - echo " : make succeeded - full coupler." + echo "::note title=Build Succeeded:: null model with full coupler built successfully." else - echo " : make failed - full coupler." + echo "::error title=Build Failed:: null model with full coupler failed compilation." exit 1 fi @@ -164,13 +169,11 @@ make -j NETCDF=3 DEBUG=on coupler_simple_test.x # Report on the status of the build if [ $? -eq 0 ] then - echo " : make succeeded - simple coupler." + echo "::note title=Build Succeeded:: null model with simple coupler built successfully." else - echo " : make failed - simple coupler." + echo "::error title=Build Failed:: null model with simple coupler failed compilation." exit 1 fi -### 17FEB2021 exit 0 to prevent model running. This is temporary -exit 0 # Run the null models test # Setup the run directory mkdir ${bld_dir}/run @@ -184,15 +187,14 @@ tar zxf ${tarFile} # Get the full namelist ln -s input-full.nml input.nml # Run the null model with the full coupler -### 17FEB2021 commented out the run because it crashes -#mpiexec -n 1 ${bld_dir}/coupler_full_test.x +mpiexec -n 1 ${bld_dir}/coupler_full_test.x # Report on the status of the run with the full coupler if [ $? -eq 0 ] then - echo " : run succeeded - full coupler." + echo "::note title=Run Succeeded - full coupler:: Full coupler null model ran successfully." else - echo " : run failed - full coupler." + echo "::error title=Run Failed - full coupler:: Full coupler null model run failed execution." exit 1 fi @@ -204,6 +206,13 @@ mkdir RESTART rm input.nml ln -s input-simple.nml input.nml # Run the null simple coupler test -### 17FEB2021 commented out the run because it crashes -#mpiexec -n 1 ${bld_dir}/coupler_simple_test.x +mpiexec -n 1 ${bld_dir}/coupler_simple_test.x +# Report on the status of the run with the simple coupler +if [ $? -eq 0 ] +then + echo "::note title=Run Succeeded - simple coupler:: simple coupler null model ran successfully" +else + echo "::error title=Run Failed - simple coupler:: simple coupler null model run failed execution." + exit 1 +fi