diff --git a/python_modules/dagster/dagster/_core/definitions/declarative_automation/automation_condition.py b/python_modules/dagster/dagster/_core/definitions/declarative_automation/automation_condition.py index b92b0cc523ef6..f8d54fcdda352 100644 --- a/python_modules/dagster/dagster/_core/definitions/declarative_automation/automation_condition.py +++ b/python_modules/dagster/dagster/_core/definitions/declarative_automation/automation_condition.py @@ -523,6 +523,20 @@ def any_deps_in_progress() -> "AnyDepsCondition": "any_deps_in_progress" ) + @experimental + @staticmethod + def all_deps_blocking_checks_passed() -> "AllDepsCondition": + """Returns an AutomationCondition that is true for any partition where all upstream + blocking checks have passed, or will be requested. + """ + with disable_dagster_warnings(): + return AutomationCondition.all_deps_match( + AutomationCondition.all_checks_match( + AutomationCondition.check_passed() | AutomationCondition.will_be_requested(), + blocking_only=True, + ).with_label("all_blocking_checks_passed") + ).with_label("all_deps_blocking_checks_passed") + @experimental @staticmethod def all_deps_updated_since_cron(