Fix: Exclude seed models from default plan end date calculation#5720
Merged
themisvaltinos merged 3 commits intomainfrom Mar 6, 2026
Merged
Fix: Exclude seed models from default plan end date calculation#5720themisvaltinos merged 3 commits intomainfrom
themisvaltinos merged 3 commits intomainfrom
Conversation
erindru
reviewed
Mar 5, 2026
tests/core/test_context.py
Outdated
| assert max_ends[seed_fqns[0]] == to_timestamp("2024-06-01") | ||
|
|
||
| # the plan start date 2025-01-01 is after the seeds end date but shouldnt cause the plan to fail | ||
| context.plan( |
Collaborator
There was a problem hiding this comment.
This test could be improved by inspecting the Plan object returned from context.plan() and verifying what dates it used
Contributor
Author
There was a problem hiding this comment.
good point added to check the dates from the plan
cdf0b53 to
913a02a
Compare
erindru
approved these changes
Mar 6, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Seed models are evaluated when first loaded and their interval end is set at that point. This might become a problem when a pr introduces a new model that depends on an existing seed. in that case the seed is the only model with intervals in prod so its stale interval end becomes the default plan end date. Now if
default_pr_startis configured (say "6 days ago" or a specific hardcoded value) it can resolve to a timestamp newer than the seeds frozen interval end causing the plan to fail with:This excludes the seed models intervals from the default end calculation to avoid this, the test shows an example of how this can happen.