ESCOMP / mizuRoute

Reach-based river routing model
http://escomp.github.io/mizuRoute/
GNU General Public License v3.0
42 stars 52 forks source link

Add timestamp to rpointer files, but make it backwards compatible with files without the timestamp #484

Open ekluzek opened 2 days ago

ekluzek commented 2 days ago

CESM is going to a system wide change where the restart rpointer text files will have the simulation timestamp in the filename. However, the model will still be backwards compatible to use the older filenames without it. But, new rpointer files created by the model will have the timestamp in the filename.

PR's for CTSM and MOSART for this work are here:

https://github.com/ESCOMP/CTSM/pull/2757 https://github.com/ESCOMP/MOSART/pull/105

ekluzek commented 2 days ago

@nmizukami and I talked about this and went over what needs to change in the code.

In MOSART and CTSM the restart file was being read to initialize time -- so there were changes around setting the clock based on the clock from the driver rather than the restart file. MizuRoute is already doing that, so that part doesn't need to happen.

What does need to change is the hardcoded rnptfil in route/build/src/public_vars.f90. As well as io_rpointfil.f90 which handles the rpointer file for read and write. Although it could also be left alone and rpntfil updated before the rpointer file is handled. For the backwards compatibility part both the filename with the timestamp on it need to be allowed as well as the generic version.

@nmizukami thinks he'll be able to do this in the next few weeks to a month so that it can come into cesm3_0_beta04. Since, it's not critical for beta04 that should be fine. So we'll have @nmizukami work on this, unless he can't get to it and someone else can get to it beforehand.

ekluzek commented 2 days ago

This will also need a tag for it, so it can go into cesm3_0_beta04.

ekluzek commented 2 days ago

@jedwards4b notes in an offline email that it isn't absolutely required in beta04, but will be for follow on updates coming into CESM post beta04.

To be clear - the rpointer changes are backward compatible in the sense that current functionality will continue to work for all components. That is - we don't need to change mizuroute or rtm for beta04. New functionality will require the change.