Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix: Selectively widen restatement intervals if they affect a downstream model that cannot be partially restated #3902

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

erindru
Copy link
Collaborator

@erindru erindru commented Feb 26, 2025

Prior to this PR, if you had something like A [incremental_by_time_range] <- B[incremental_by_unique_key] and tried to restate a part of A, B would only be fully restated if it was in prod.

If B was in a dev environment, then it would be partially restated even though it's a model type that doesn't support partial restatement. If B was later promoted to prod, then this could lead to incorrect data in prod.

This PR adjusts the logic to, when calculating restatement intervals based on SnapshotTableInfo, if any of the affected snapshots are "full restatement only" then the full snapshot records are fetched from state so that the restatement intervals can be widened correctly.

@erindru erindru changed the title Fix: Widen restatement intervals if they affect a model that cannot be partially restated Fix: Selectively widen restatement intervals if they affect a downstream model that cannot be partially restated Feb 26, 2025
…tream model that cannot be partially restated
@erindru erindru force-pushed the erin/fix-restatements branch from f8f7410 to 9bf1a12 Compare February 26, 2025 03:01
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.

1 participant