Skip to content

Allow skipping checks of some tracer fields#678

Merged
billsacks merged 1 commit into
ESCOMP:mainfrom
billsacks:water_tracers_skip_checks
Jul 15, 2026
Merged

Allow skipping checks of some tracer fields#678
billsacks merged 1 commit into
ESCOMP:mainfrom
billsacks:water_tracers_skip_checks

Conversation

@billsacks

Copy link
Copy Markdown
Member

Description of changes

The irrigation tracer field is not yet mapped correctly (see #675). In order to allow both irrigation and volr to be spatially-varying but to still have tracer checks for everything else, we now exclude the irrigation field from these tracer checks.

This depends on the CESM_share changes in ESCOMP/CESM_share#85

Specific notes

Contributors other than yourself, if any:

CMEPS Issues Fixed (include github issue #):

Are changes expected to change answers? (specify if bfb, different at roundoff, more substantial) - no: bfb

Any User Interface Changes (namelist or namelist defaults changes)? Adds water_tracers_variables_not_checked namelist item

Testing performed

Please describe the tests along with the target model and machine(s)
If possible, please also added hashes that were used in the testing

SMS_D_Ld2.f19_g17.X.green_gnu.drv-water_tracers--drv-glc_avg_frequently in cesm3_0_alpha09d, with share updated to share1.1.21

The irrigation tracer field is not yet mapped correctly (see
ESCOMP#675). In order to allow both
irrigation and volr to be spatially-varying but to still have tracer
checks for everything else, we now exclude the irrigation field from
these tracer checks.

(This requires a change to the share code to implement this skip.)
@billsacks billsacks requested a review from nusbaume July 14, 2026 22:32
Comment on lines +2835 to +2841
if (.not. isPresentNonTracer) then
! This is the situation for a small number of fields where we have a tracer
! field without a corresponding non-tracer field.
if (dbug_flag > 5) then
call ESMF_LogWrite(trim(subname)//": Skipping check for <" // trim(FBName)//"%"//trim(fieldNameList(n)) // &
"> which has no corresponding non-tracer field", ESMF_LOGMSG_INFO)
end if

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks like a bigger diff than it really is: The conditional has been rearranged so that this .not. isPresentNonTracer is the first block, and then the standard case is in the else. This made sense at first because there were going to be multiple skip conditions so it was going to look like:

if (.not. isPresentNonTracer) then
   ...
else if (variable_in_skip_list) then
   ...
else
   ! standard case, not skipped
end if

It ended up making more sense to put the variable-in-skip-list check inside the main code branch - because it was simplest to check/set this in the wtracers_check_tracer_ratios call - but I felt like I marginally liked this conditional block arrangement better because it lends itself better to possible future changes (such as new ways to skip a variable), and I had already done testing with this code structure, so I decided to leave this change in place.

@nusbaume nusbaume left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @billsacks!

@billsacks billsacks merged commit 4d4b45a into ESCOMP:main Jul 15, 2026
1 check passed
@billsacks billsacks deleted the water_tracers_skip_checks branch July 15, 2026 02:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants