File tree Expand file tree Collapse file tree 1 file changed +4
-1
lines changed
Expand file tree Collapse file tree 1 file changed +4
-1
lines changed Original file line number Diff line number Diff line change @@ -656,6 +656,9 @@ def to_sqlmesh(
656656 # Set allow_partials to True for dbt models to preserve the original semantics.
657657 allow_partials = True
658658
659+ # pop begin for all models so we don't pass it through for non-incremental materializations
660+ # (happens if model config is microbatch but project config overrides)
661+ begin = model_kwargs .pop ("begin" , None )
659662 if kind .is_incremental :
660663 if self .batch_size and isinstance (self .batch_size , str ):
661664 if "interval_unit" in model_kwargs :
@@ -665,7 +668,7 @@ def to_sqlmesh(
665668 else :
666669 model_kwargs ["interval_unit" ] = self .batch_size
667670 self .batch_size = None
668- if begin := model_kwargs . pop ( "begin" , None ) :
671+ if begin :
669672 if "start" in model_kwargs :
670673 get_console ().log_warning (
671674 f"Both 'begin' and 'start' are set for model '{ self .canonical_name (context )} '. 'start' will be used."
You can’t perform that action at this time.
0 commit comments