Skip to content

Commit

Permalink
updated buildnml to ctsm5.3.011
Browse files Browse the repository at this point in the history
  • Loading branch information
mvertens committed Nov 17, 2024
1 parent 13f8ff9 commit a76706f
Showing 1 changed file with 7 additions and 17 deletions.
24 changes: 7 additions & 17 deletions cime_config/buildnml
Original file line number Diff line number Diff line change
Expand Up @@ -75,8 +75,7 @@ def buildnml(case, caseroot, compname):
run_reftod = case.get_value("RUN_REFTOD")
start_tod = case.get_value("START_TOD")
glc_nec = case.get_value("GLC_NEC")
cism_use_antarctica = case.get_value("CISM_USE_ANTARCTICA")
dglc_use_antarctica = case.get_value("DGLC_USE_ANTARCTICA")
glc_use_antarctica = case.get_value("GLC_USE_ANTARCTICA")
mask = case.get_value("MASK_GRID")
driver = case.get_value("COMP_INTERFACE").lower()

Expand Down Expand Up @@ -247,29 +246,20 @@ def buildnml(case, caseroot, compname):
else:
nomeg = ""

glc_use_antarctica = cism_use_antarctica
if glc_use_antarctica is None:
glc_use_antarctica = dglc_use_antarctica
if glc_use_antarctica is None:
# This is the case for compsets without CISM or DGLC, where the
# CISM_USE_ANTARCTICA and DGLC_USE_ANTARCTICA xml variables are not defined
# This is the case for compsets with SGLC where the GLC_USE_ANTARCTICA xml
# variable isn't defined
glc_use_antarctica_flag = ""
elif isinstance(glc_use_antarctica, bool):
if glc_use_antarctica:
glc_use_antarctica_flag = "-glc_use_antarctica"
else:
glc_use_antarctica_flag = ""
else:
if cism_use_antarctia:
expect(
False,
"Unexpected value for CISM_USE_ANTARCTICA: {}".format(cism_use_antarctica),
)
else:
expect(
False,
"Unexpected value for DGLC_USE_ANTARCTICA: {}".format(dglc_use_antarctica),
)
expect(
False,
"Unexpected value for GLC_USE_ANTARCTICA: {}".format(glc_use_antarctica),
)

if clm_nml_use_case != "UNSET":
usecase = "-use_case %s" % clm_nml_use_case
Expand Down

0 comments on commit a76706f

Please sign in to comment.