Skip to content

Commit b67c335

Browse files
committed
Fix: Remove leftover forward-only category usage when categorizing orphaned snapshots (#5190)
1 parent 4e80a93 commit b67c335

File tree

1 file changed

+5
-11
lines changed

1 file changed

+5
-11
lines changed

sqlmesh/core/plan/builder.py

Lines changed: 5 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -726,17 +726,11 @@ def _get_orphaned_indirect_change_category(
726726
# One of the new parents in the chain was breaking so this indirect snapshot is breaking
727727
return SnapshotChangeCategory.INDIRECT_BREAKING
728728

729-
if SnapshotChangeCategory.FORWARD_ONLY in previous_parent_categories:
730-
# One of the new parents in the chain was forward-only so this indirect snapshot is forward-only
731-
indirect_category = SnapshotChangeCategory.FORWARD_ONLY
732-
elif (
733-
previous_parent_categories.intersection(
734-
{
735-
SnapshotChangeCategory.NON_BREAKING,
736-
SnapshotChangeCategory.INDIRECT_NON_BREAKING,
737-
}
738-
)
739-
and indirect_category != SnapshotChangeCategory.FORWARD_ONLY
729+
if previous_parent_categories.intersection(
730+
{
731+
SnapshotChangeCategory.NON_BREAKING,
732+
SnapshotChangeCategory.INDIRECT_NON_BREAKING,
733+
}
740734
):
741735
# All changes in the chain were non-breaking so this indirect snapshot can be non-breaking too
742736
indirect_category = SnapshotChangeCategory.INDIRECT_NON_BREAKING

0 commit comments

Comments
 (0)