1616)
1717from sqlmesh .core .context_diff import ContextDiff
1818from sqlmesh .core .environment import EnvironmentNamingInfo
19- from sqlmesh .core .plan .common import should_force_rebuild
19+ from sqlmesh .core .plan .common import should_force_rebuild , is_breaking_kind_change
2020from sqlmesh .core .plan .definition import (
2121 Plan ,
2222 SnapshotMapping ,
@@ -597,7 +597,7 @@ def _categorize_snapshots(
597597 forward_only = self ._forward_only or self ._is_forward_only_change (s_id )
598598 if forward_only and s_id .name in self ._context_diff .modified_snapshots :
599599 new , old = self ._context_diff .modified_snapshots [s_id .name ]
600- if should_force_rebuild (old , new ) or snapshot .is_seed :
600+ if is_breaking_kind_change (old , new ) or snapshot .is_seed :
601601 # Breaking kind changes and seed changes can't be forward-only.
602602 forward_only = False
603603
@@ -622,7 +622,7 @@ def _categorize_snapshot(
622622 if self ._context_diff .directly_modified (s_id .name ):
623623 if self ._auto_categorization_enabled :
624624 new , old = self ._context_diff .modified_snapshots [s_id .name ]
625- if should_force_rebuild (old , new ):
625+ if is_breaking_kind_change (old , new ):
626626 snapshot .categorize_as (SnapshotChangeCategory .BREAKING , False )
627627 return
628628
@@ -780,7 +780,7 @@ def _is_forward_only_change(self, s_id: SnapshotId) -> bool:
780780 if snapshot .name in self ._context_diff .modified_snapshots :
781781 _ , old = self ._context_diff .modified_snapshots [snapshot .name ]
782782 # If the model kind has changed in a breaking way, then we can't consider this to be a forward-only change.
783- if snapshot .is_model and should_force_rebuild (old , snapshot ):
783+ if snapshot .is_model and is_breaking_kind_change (old , snapshot ):
784784 return False
785785 return (
786786 snapshot .is_model and snapshot .model .forward_only and bool (snapshot .previous_versions )
0 commit comments