Skip to content

Add support for time intervals in HH:MM:SS and similar formats#329

Merged
xylar merged 3 commits intoE3SM-Project:developfrom
xylar:omega/fix-time-step-hh-mm-ss
Feb 2, 2026
Merged

Add support for time intervals in HH:MM:SS and similar formats#329
xylar merged 3 commits intoE3SM-Project:developfrom
xylar:omega/fix-time-step-hh-mm-ss

Conversation

@xylar
Copy link

@xylar xylar commented Jan 15, 2026

This merge adds support for time intervals in the following formats:

  • DDDD_HH:MM:SS(.sss...) (previously supported)
  • HH:MM:SS(.sss...)
  • MM:SS(.sss...)
  • SS(.sss...)

This will make compatibility with Polaris and MPAS-Ocean simpler, see E3SM-Project/polaris#444.

Checklist

  • Documentation:
  • Linting
  • Building
    • CMake build does not produce any new warnings from changes in this PR
  • Testing
    • Add a comment to the PR titled Testing with the following:
      • Which machines CTest unit tests
        have been run on and indicate that are all passing.
      • The Polaris omega_pr test suite
        has passed, using the Polaris e3sm_submodules/Omega baseline
      • Document machine(s), compiler(s), and the build path(s) used for -p for both the baseline (Polaris e3sm_submodules/Omega) and the PR build
      • Indicate "All tests passed" or document failing tests
      • Document testing used to verify the changes including any tests that are added/modified/impacted.
        after.
    • New tests:
      • CTest unit tests for new features have been added per the approved design.

Fixes E3SM-Project/polaris#444

xylar added 3 commits January 14, 2026 08:44
These exercise the `TimeInterval(std::string&)` constructor used by
`TimeIntegration` options like `TimeStep` and `RunDuration`.

For now, we're verifying that `DDDD_HH:MM:SS` type formats work and
`HH:MM:SS` (and shorter) formats fail.  Later, we will implement
support for these shorter formats and verify that they, too work.
This merge adds support for time intervals in the following
formats:
- DDDD_HH:MM:SS(.sss...)
- HH:MM:SS(.sss...)
- MM:SS(.sss...)
- SS(.sss...)

This will make compatibility with Polaris and MPAS-Ocean simpler.
@xylar
Copy link
Author

xylar commented Jan 15, 2026

Testing

Two new CTests were added to verify time-interval string support:

  • TIMEINTERVAL_PARSE_TEST
  • TIMEINTERVAL_PARSE_EXTENDED_FORMATS_TEST

CTest unit tests:

  • Machine: chrysalis
  • Compiler: intel
  • Build type: Release
  • Result: All tests passed
  • Log: /gpfs/fs1/home/ac.xylar/e3sm_work/polaris/main/build_omega/build_chrysalis_intel/ctests.log

Polaris omega_pr suite

All failures including baseline diffs are actually due to the PIO errors we have been seeing. There were missing files in the baseline run because of the PIO errors that result in seeming baseline diffs -- file present in one run and not the other.

  • Baseline workdir: /lcrc/group/e3sm/ac.xylar/polaris_0.9/chrysalis/test_20260115/omega-pr-develop
  • Baseline build: /lcrc/group/e3sm/ac.xylar/polaris_0.9/chrysalis/test_20260115/omega-pr-develop/build
  • PR build: /lcrc/group/e3sm/ac.xylar/polaris_0.9/chrysalis/test_20260115/omega-pr-fix-time-step-hh-mm-ss/build
  • PR workdir: /lcrc/group/e3sm/ac.xylar/polaris_0.9/chrysalis/test_20260115/omega-pr-fix-time-step-hh-mm-ss
  • Machine: chrysalis
  • Partition: compute
  • Compiler: intel
  • Build type: <Debug|Release>
  • Log: /lcrc/group/e3sm/ac.xylar/polaris_0.9/chrysalis/test_20260115/omega-pr-fix-time-step-hh-mm-ss/polaris_omega_pr.o1125626
  • Result:
    • Failures (1 of 7):
      • ocean/planar/manufactured_solution/convergence_both/del2
    • Diffs (1 of 7):
      • ocean/spherical/icos/rotation_2d

@xylar
Copy link
Author

xylar commented Jan 15, 2026

@brian-oneill, would you be willing to review this?

@brian-oneill
Copy link

Looks good, parser handles all the different forms correctly. Ran the ctests successfully on pm-cpu and pm-gpu.

@xylar
Copy link
Author

xylar commented Feb 2, 2026

Thank you for the testing and review, @brian-oneill!

@xylar xylar self-assigned this Feb 2, 2026
@xylar xylar merged commit fc53608 into E3SM-Project:develop Feb 2, 2026
1 check passed
@xylar xylar deleted the omega/fix-time-step-hh-mm-ss branch February 2, 2026 13:43
xylar added a commit to xylar/polaris that referenced this pull request Feb 2, 2026
This merge updates the e3sm_submodules/Omega submodule from [f2e951a](https://github.com/E3SM-Project/Omega/tree/f2e951a) to [fc53608](https://github.com/E3SM-Project/Omega/tree/fc53608).

This update includes the following MPAS-Ocean and MPAS-Frameworks PRs (check mark indicates bit-for-bit with previous PR in the list):
- [ ]  (ocn) E3SM-Project/Omega#325
- [ ]  (ocn) E3SM-Project/Omega#329
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.

Fix config_dt and TimeStep so that they are always in the format DDDD_hh:mm:ss

2 participants