File tree Expand file tree Collapse file tree 2 files changed +12
-8
lines changed
sqlmesh/integrations/github/cicd Expand file tree Collapse file tree 2 files changed +12
-8
lines changed Original file line number Diff line number Diff line change @@ -33,7 +33,9 @@ class GithubCICDBotConfig(BaseConfig):
3333 pr_environment_name : t .Optional [str ] = None
3434 pr_min_intervals : t .Optional [int ] = None
3535 prod_branch_names_ : t .Optional [str ] = Field (default = None , alias = "prod_branch_name" )
36- forward_only_branch_suffix : t .Optional [str ] = None
36+ forward_only_branch_suffix_ : t .Optional [str ] = Field (
37+ default = None , alias = "forward_only_branch_suffix"
38+ )
3739
3840 @model_validator (mode = "before" )
3941 @classmethod
@@ -74,6 +76,10 @@ def skip_pr_backfill(self) -> bool:
7476 return True
7577 return self .skip_pr_backfill_
7678
79+ @property
80+ def forward_only_branch_suffix (self ) -> str :
81+ return self .forward_only_branch_suffix_ or "-forward-only"
82+
7783 FIELDS_FOR_ANALYTICS : t .ClassVar [t .Set [str ]] = {
7884 "invalidate_environment_after_deploy" ,
7985 "enable_deploy_command" ,
Original file line number Diff line number Diff line change @@ -478,13 +478,11 @@ def pr_targets_prod_branch(self) -> bool:
478478 return self ._pull_request .base .ref in self .bot_config .prod_branch_names
479479
480480 @property
481- def forward_only_plan (self ) -> t .Optional [bool ]:
482- if self .bot_config .forward_only_branch_suffix is not None :
483- head_ref = self ._pull_request .head .ref
484- if isinstance (head_ref , str ):
485- return head_ref .endswith (self .bot_config .forward_only_branch_suffix )
486- return False
487- return None
481+ def forward_only_plan (self ) -> bool :
482+ head_ref = self ._pull_request .head .ref
483+ if isinstance (head_ref , str ):
484+ return head_ref .endswith (self .bot_config .forward_only_branch_suffix )
485+ return False
488486
489487 @classmethod
490488 def _append_output (cls , key : str , value : str ) -> None :
You can’t perform that action at this time.
0 commit comments