Skip to content

Commit

Permalink
Remove deprecated trigger rule
Browse files Browse the repository at this point in the history
  • Loading branch information
shahar1 committed Nov 7, 2024
1 parent f52c471 commit 72f3399
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 3 deletions.
1 change: 0 additions & 1 deletion airflow/utils/trigger_rule.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@ class TriggerRule(str, Enum):
NONE_FAILED = "none_failed"
NONE_FAILED_OR_SKIPPED = "none_failed_or_skipped"
NONE_SKIPPED = "none_skipped"
DUMMY = "dummy"
ALWAYS = "always"
NONE_FAILED_MIN_ONE_SUCCESS = "none_failed_min_one_success"
ALL_SKIPPED = "all_skipped"
Expand Down
5 changes: 5 additions & 0 deletions newsfragments/43368.significant.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
Deprecated trigger rule removed

**Breaking Change**

The trigger rule prior to TriggerRule.ALWAYS was removed.
3 changes: 1 addition & 2 deletions tests/utils/test_trigger_rule.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,11 +34,10 @@ def test_valid_trigger_rules(self):
assert TriggerRule.is_valid(TriggerRule.NONE_FAILED)
assert TriggerRule.is_valid(TriggerRule.NONE_FAILED_OR_SKIPPED)
assert TriggerRule.is_valid(TriggerRule.NONE_SKIPPED)
assert TriggerRule.is_valid(TriggerRule.DUMMY)
assert TriggerRule.is_valid(TriggerRule.ALWAYS)
assert TriggerRule.is_valid(TriggerRule.NONE_FAILED_MIN_ONE_SUCCESS)
assert TriggerRule.is_valid(TriggerRule.ALL_DONE_SETUP_SUCCESS)
assert len(TriggerRule.all_triggers()) == 14
assert len(TriggerRule.all_triggers()) == 13

with pytest.raises(ValueError):
TriggerRule("NOT_EXIST_TRIGGER_RULE")

0 comments on commit 72f3399

Please sign in to comment.