diff --git a/bld/namelist_files/use_cases/aquaplanet_cam5.xml b/bld/namelist_files/use_cases/aquaplanet_cam5.xml
index 814eecd98f..f5a3ed7988 100644
--- a/bld/namelist_files/use_cases/aquaplanet_cam5.xml
+++ b/bld/namelist_files/use_cases/aquaplanet_cam5.xml
@@ -18,9 +18,7 @@
348.0e-6
-atm/cam/solar/ape_solar_ave_tsi_1365.nc
-.true.
-/
+atm/cam/solar/ape_solar_ave_tsi_1365.nc
apeozone_cam3_5_54.nc
diff --git a/bld/namelist_files/use_cases/aquaplanet_cam6.xml b/bld/namelist_files/use_cases/aquaplanet_cam6.xml
index 814eecd98f..f5a3ed7988 100644
--- a/bld/namelist_files/use_cases/aquaplanet_cam6.xml
+++ b/bld/namelist_files/use_cases/aquaplanet_cam6.xml
@@ -18,9 +18,7 @@
348.0e-6
-atm/cam/solar/ape_solar_ave_tsi_1365.nc
-.true.
-/
+atm/cam/solar/ape_solar_ave_tsi_1365.nc
apeozone_cam3_5_54.nc
diff --git a/bld/namelist_files/use_cases/aquaplanet_rce_cam6.xml b/bld/namelist_files/use_cases/aquaplanet_rce_cam6.xml
index f03c4294b2..7b93fa8418 100644
--- a/bld/namelist_files/use_cases/aquaplanet_rce_cam6.xml
+++ b/bld/namelist_files/use_cases/aquaplanet_rce_cam6.xml
@@ -1,8 +1,9 @@
-
-
+
+ atm/cam/inic/se/initial_data.cam.ne30.L32.RCEMIP_c20190507.nc
+
0.
0.
@@ -12,18 +13,6 @@
false
- atm/cam/ozone/
- ozone.cam.ne30.L32.RCEMIP_c20190507.nc
- atm/cam/inic/se/initial_data.cam.ne30.L32.RCEMIP_c20190507.nc
- atm/cam/solar/solar_tsi_551_with_ssi.cam.ne30.L32.RCEMIP_c20190507.nc
- .false.
-
- true
- I
- 1
- 1
- 'T','Q','U','V','PS','PRECT','Z3'
-
1.650e-6
0.306e-6
@@ -32,13 +21,12 @@
0.0
0.0
-
-atm/cam/solar/ape_solar_ave_tsi_1365.nc
-.true.
-/
+
+ atm/cam/solar/solar_tsi_551_with_ssi.cam.ne30.L32.RCEMIP_c20190507.nc
+ .false.
-
-apeozone_cam3_5_54.nc
+
+ ozone.cam.ne30.L32.RCEMIP_c20190507.nc
atm/cam/ozone
OZONE
CYCLICAL
@@ -48,7 +36,6 @@
.true.
0.73391095
-
0.0
86164.10063718943
@@ -67,4 +54,10 @@
""
0.0
+ true
+ I
+ 1
+ 1
+ 'T','Q','U','V','PS','PRECT','Z3'
+
diff --git a/cime_config/buildcpp b/cime_config/buildcpp
index 9143f2bcb6..5bbcf7d851 100644
--- a/cime_config/buildcpp
+++ b/cime_config/buildcpp
@@ -15,7 +15,7 @@ sys.path.append(os.path.join(CIMEROOT, "CIME", "Tools"))
from standard_script_setup import *
-from CIME.utils import run_cmd_no_fail
+from CIME.utils import run_cmd
from CIME.case import Case
from CIME.buildnml import parse_input
@@ -127,7 +127,10 @@ def buildcpp(case):
srcroot = testpath
cmd = os.path.join(srcroot, "bld", "configure") + \
" " + " ".join(config_opts)
- run_cmd_no_fail(cmd, from_dir=camconf)
+
+ stat, output, err = run_cmd(cmd, from_dir=camconf)
+ if stat:
+ logger.warning(err)
# determine cppdefs - caseroot/camconf/CESM_cppdefs is created by the call to configure
with open(os.path.join(camconf, "CESM_cppdefs"), 'r') as f:
diff --git a/doc/ChangeLog b/doc/ChangeLog
index 4cadb540a6..b198448dc7 100644
--- a/doc/ChangeLog
+++ b/doc/ChangeLog
@@ -1,5 +1,106 @@
===============================================================
+Tag name: cam6_4_015
+Originator(s): jedwards, eaton
+Date: 23 July 2024
+One-line Summary: misc fixes: buildcpp, check_energy
+Github PR URL: https://github.com/ESCOMP/CAM/pull/1072
+
+Purpose of changes (include the issue number and title text for each relevant GitHub issue):
+
+. Issue #1045 - buildcpp does not report errors reported by cam configure
+ - modify buildcpp so that error messages from CAM's configure appear in
+ the log output
+
+. Issue #1015 - SILHS subcolumns output as all zeros.
+ - testing for this issue revealed a bug when subcolumns were used with
+ the SE dycore. A fix is added to check_energy.F90. This doesn't fix
+ the problem with zeros in the subcolumn output, but that is the same
+ problem previously reported for COSP in issue #944. The problem only
+ appears when SE grid output is interpolated. A workaround is to output
+ the subcolumns on the native SE grid.
+
+. Issue #1044 - Remove solar_htng_spctrl_scl from aquaplanet use case
+ - also cleaned up the aquaplanet_rce_cam6.xml file which had duplicated
+ settings of several variables. The second setting is not used because
+ the first setting takes precedence. Note that the setting of
+ solar_htng_spctrl_scl to false in aquaplanet_rce_cam6.xml is needed
+ because it is overriding the default of true for cam6 with RRTMG.
+
+. resolves #1045 (and replaces PR #1046)
+. resolves #1015
+. resolves #1044
+
+Describe any changes made to build system: none
+
+Describe any changes made to the namelist: none
+
+List any changes to the defaults for the boundary datasets: none
+
+Describe any substantial timing or memory changes: none
+
+Code reviewed by: cacraig
+
+List all files eliminated: none
+
+List all files added and what they do: none
+
+List all existing files that have been modified, and describe the changes:
+
+bld/namelist_files/use_cases/aquaplanet_cam5.xml
+bld/namelist_files/use_cases/aquaplanet_cam6.xml
+. remove solar_htng_spctrl_scl
+
+bld/namelist_files/use_cases/aquaplanet_rce_cam6.xml
+. remove duplicated (and hence unused) settings for solar_irrad_data_file,
+ prescribed_ozone_file, and solar_htng_spctrl_scl
+
+cime_config/buildcpp
+. run configure command from run_cmd() rather than run_cmd_no_fail() and
+ pass error output to logger.warning()
+
+src/physics/cam/check_energy.F90
+. fix out of bounds array references when subcolumns are used in the SE
+ specific hydrostatic energy scaling.
+
+
+If there were any failures reported from running test_driver.sh on any test
+platform, and checkin with these failures has been OK'd by the gatekeeper,
+then copy the lines from the td.*.status files for the failed tests to the
+appropriate machine below. All failed tests must be justified.
+
+derecho/intel/aux_cam:
+
+ERP_Ln9.f09_f09_mg17.FCSD_HCO.derecho_intel.cam-outfrq9s (Overall: FAIL)
+- pre-existing failure due to HEMCO not having reproducible results issues #1018 and #856
+
+SMS_D_Ln9_P1280x1.ne0ARCTICne30x4_ne0ARCTICne30x4_mt12.FHIST.derecho_intel.cam-outfrq9s (Overall: PEND)
+SMS_D_Ln9_P1280x1.ne0CONUSne30x8_ne0CONUSne30x8_mt12.FCHIST.derecho_intel.cam-outfrq9s (Overall: PEND)
+- pre-existing failures -- need fix in CLM external
+
+SMS_D_Ln9.T42_T42.FSCAM.derecho_intel.cam-outfrq9s (Overall: FAIL)
+- pre-existing failure -- need fix in CICE external
+
+izumi/nag/aux_cam:
+
+DAE.f45_f45_mg37.FHS94.izumi_nag.cam-dae (Overall: FAIL) details:
+- pre-existing failure - issue #670
+
+izumi/gnu/aux_cam:
+
+ERP_D_Ln9.ne3pg3_ne3pg3_mg37.QPC6.izumi_gnu.cam-outfrq9s_rrtmgp (Overall: DIFF)
+- solution diffs because solar_htng_spctrl_scl is now getting the correct
+ value of .false. (what RRTMGP requires). The use case file was
+ previously incorrectly setting this value to .true. (what RRTMG requires).
+
+CAM tag used for the baseline comparison tests if different than previous
+tag:
+
+Summarize any changes to answers: BFB
+
+===============================================================
+===============================================================
+
Tag name: cam6_4_014
Originator(s): fvitt
Date: 22 Jul 2024
diff --git a/src/physics/cam/check_energy.F90 b/src/physics/cam/check_energy.F90
index 7615f0e432..1410a52a2f 100644
--- a/src/physics/cam/check_energy.F90
+++ b/src/physics/cam/check_energy.F90
@@ -485,13 +485,14 @@ subroutine check_energy_chng(state, tend, name, nstep, ztodt, &
!
if (state%psetcols == pcols) then
cp_or_cv(:ncol,:) = cp_or_cv_dycore(:ncol,:,lchnk)
+ scaling(:ncol,:) = cpairv(:ncol,:,lchnk)/cp_or_cv_dycore(:ncol,:,lchnk)
else
cp_or_cv(:ncol,:) = cpair
+ scaling(:ncol,:) = 1.0_r8
endif
!
! enthalpy scaling for energy consistency
!
- scaling(:ncol,:) = cpairv(:ncol,:,lchnk)/cp_or_cv_dycore(:ncol,:,lchnk)
temp(1:ncol,:) = state%temp_ini(1:ncol,:)+scaling(1:ncol,:)*(state%T(1:ncol,:)-state%temp_ini(1:ncol,:))
call get_hydrostatic_energy(state%q(1:ncol,1:pver,1:pcnst),.true., &
state%pdel(1:ncol,1:pver), cp_or_cv(1:ncol,1:pver), &