Description
Currently "start" for a plan is shared across all models while "end" is model-specific. In order to complete this issue, start must also become model-specific like end. It might be best to isolate that change in PR and validate it's behavior before adding "relative start" described below.
"relative start" is a relative time value ("1 week ago", "2 months ago", ect.) that a user can provide instead of start. What it means it the following:
- Take your model-specific end, and subtract the relative amount from it
- If the computed start/end range does not cover a complete interval, then move start further back until 1 interval is loaded
Once done, all models will have between 1 and N cron intervals loaded where N is technically the number of intervals most granular model can have for the relative time provided. A realistic example, if I have a mixture of daily and monthly models, then the range for "1 week ago" would be between 1 and 7 with 1 being the monthly models and 7 being the daily models.
Note that this is a new argument so existing "start" is untouched and the behavior should be the same. We should consider validating that what is provided to plan for "relative_start" is truly a relative value and not an absolute.
Once this is added to plan, then the CI/CD bot needs updated to add a new config which is default_pr_relative_start
. The value provided for this would be used for the plan's relative_start
. Add a deprecation notice for default_pr_start
and tell users to use default_pr_relative_start
instead. We are deprecating here since this is a change in functionality.