You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by GitBox <gi...@apache.org> on 2021/07/14 23:01:15 UTC

[GitHub] [airflow] raphaelauv opened a new issue #17012: NONE_FAILED_OR_SKIPPED and NONE_FAILED do the same

raphaelauv opened a new issue #17012:
URL: https://github.com/apache/airflow/issues/17012


   **Apache Airflow version**:
   2.1.2
   
   **What happened**:
   
   https://github.com/apache/airflow/blob/16c55f100374df8cb17a85d06396aa42785fed0e/airflow/ti_deps/deps/trigger_rule_dep.py#L206
   
   and 
   
   https://github.com/apache/airflow/blob/16c55f100374df8cb17a85d06396aa42785fed0e/airflow/ti_deps/deps/trigger_rule_dep.py#L216
   
   is the same code, so both look like doing the same
   **What you expected to happen**:
   
   
   
   <!-- What do you think went wrong? -->
   
   NONE_FAILED_OR_SKIPPED should do the same than ALL_SUCCESS
   
   maybe NONE_FAILED_OR_SKIPPED could be removed.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] uranusjr commented on issue #17012: NONE_FAILED_OR_SKIPPED and NONE_FAILED do the same

Posted by GitBox <gi...@apache.org>.
uranusjr commented on issue #17012:
URL: https://github.com/apache/airflow/issues/17012#issuecomment-882907844


   I `git blame`-ed this and `NONE_FAILED_OR_SKIPPED` was added in #7464. `NONE_FAILED_OR_SKIPPED` is intentionally implemented to be almost exactly the same as `NONE_FAILED`, but sets the state of the *current* task differently.
   
   https://github.com/apache/airflow/blob/16c55f100374df8cb17a85d06396aa42785fed0e/airflow/ti_deps/deps/trigger_rule_dep.py#L128-L156
   
   Assuming no upstream fails…
   
   * `ALL_SUCCESS` skips the current task if at least one upstream is skipped.
   * `NONE_FAILED` does nothing (continues the current task).
   * `NONE_FAILED_OR_SKIPPED` skips the current task only if *all* upstream tasks are skipped, otherwise continues.
   
   So I don’t think we can afford to change anything.
   
   cc @yuqian90 maybe you could recall some of the context here?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] yuqian90 commented on issue #17012: NONE_FAILED_OR_SKIPPED and NONE_FAILED do the same

Posted by GitBox <gi...@apache.org>.
yuqian90 commented on issue #17012:
URL: https://github.com/apache/airflow/issues/17012#issuecomment-883089001


   @uranusjr already explained the differences between these states. I just want to re-iterate that `none_failed_or_skipped` and `none_failed` are different. The difference is explained in [Trigger Rules](https://airflow.apache.org/docs/apache-airflow/stable/concepts/dags.html#trigger-rules).
   
   In the documented example, if `join` is set to `none_failed_or_skipped`, it is skipped when both `branch_false` and `follow_branch_a` are skipped. However, if `join` is set to `none_failed`, it will be `success` even if both `branch_false` and `follow_branch_a` are skipped.
   ![image](https://user-images.githubusercontent.com/6637585/126268585-a4ac658e-95f9-4b55-a5ed-097a8cb5c66b.png)
   
   In practices, I do find the `none_failed_or_skipped` behaviour more useful, especially when used to join branching logic. However, I don't know if any users out there prefer the behaviour of `none_failed`.
   
   The code that causes such difference can be found here:
   https://github.com/apache/airflow/blob/866a601b76e219b3c043e1dbbc8fb22300866351/airflow/ti_deps/deps/trigger_rule_dep.py#L146


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] uranusjr edited a comment on issue #17012: NONE_FAILED_OR_SKIPPED and NONE_FAILED do the same

Posted by GitBox <gi...@apache.org>.
uranusjr edited a comment on issue #17012:
URL: https://github.com/apache/airflow/issues/17012#issuecomment-882907844






-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] uranusjr edited a comment on issue #17012: NONE_FAILED_OR_SKIPPED and NONE_FAILED do the same

Posted by GitBox <gi...@apache.org>.
uranusjr edited a comment on issue #17012:
URL: https://github.com/apache/airflow/issues/17012#issuecomment-882907844






-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] raphaelauv commented on issue #17012: NONE_FAILED_OR_SKIPPED and NONE_FAILED do the same

Posted by GitBox <gi...@apache.org>.
raphaelauv commented on issue #17012:
URL: https://github.com/apache/airflow/issues/17012#issuecomment-886526633


   @uranusjr thanks for the explanation.
   
   So we could maybe rename NONE_FAILED_OR_SKIPPED by NONE_FAILED_OR_ALL_SKIPPED ?
   
   That would be more explicit.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] raphaelauv edited a comment on issue #17012: NONE_FAILED_OR_SKIPPED is unclear

Posted by GitBox <gi...@apache.org>.
raphaelauv edited a comment on issue #17012:
URL: https://github.com/apache/airflow/issues/17012#issuecomment-886526633


   @uranusjr thanks for the explanation.
   
   So we could maybe rename **NONE_FAILED_OR_SKIPPED** by **NONE_FAILED_AND_AT_LEAST_ONE_SUCCED** ?
   
   That would be more explicit.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] eladkal commented on issue #17012: NONE_FAILED_OR_SKIPPED is unclear

Posted by GitBox <gi...@apache.org>.
eladkal commented on issue #17012:
URL: https://github.com/apache/airflow/issues/17012#issuecomment-901116949


   @raphaelauv if you want to take it and run your suggestion in the mailing list and if accepted to open a PR you are more than welcome.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] eladkal commented on issue #17012: NONE_FAILED_OR_SKIPPED is unclear

Posted by GitBox <gi...@apache.org>.
eladkal commented on issue #17012:
URL: https://github.com/apache/airflow/issues/17012#issuecomment-894701749


   Is the issue here only the name of the trigger rule?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] kaxil closed issue #17012: NONE_FAILED_OR_SKIPPED is unclear

Posted by GitBox <gi...@apache.org>.
kaxil closed issue #17012:
URL: https://github.com/apache/airflow/issues/17012


   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] potiuk commented on issue #17012: NONE_FAILED_OR_SKIPPED and NONE_FAILED do the same

Posted by GitBox <gi...@apache.org>.
potiuk commented on issue #17012:
URL: https://github.com/apache/airflow/issues/17012#issuecomment-882808812


   Looks about right. For the sake of backwards compatibility I'd merge it in one IF and deprecate one of those. Anyone?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] uranusjr commented on issue #17012: NONE_FAILED_OR_SKIPPED and NONE_FAILED do the same

Posted by GitBox <gi...@apache.org>.
uranusjr commented on issue #17012:
URL: https://github.com/apache/airflow/issues/17012#issuecomment-882907844


   I `git blame`-ed this and `NONE_FAILED_OR_SKIPPED` was added in #7464. `NONE_FAILED_OR_SKIPPED` is intentionally implemented to be almost exactly the same as `NONE_FAILED`, but sets the state of the *current* task differently.
   
   https://github.com/apache/airflow/blob/16c55f100374df8cb17a85d06396aa42785fed0e/airflow/ti_deps/deps/trigger_rule_dep.py#L128-L156
   
   Assuming no upstream fails…
   
   * `ALL_SUCCESS` skips the current task if at least one upstream is skipped.
   * `NONE_FAILED` does nothing (continues the current task).
   * `NONE_FAILED_OR_SKIPPED` skips the current task only if *all* upstream tasks are skipped, otherwise continues.
   
   So I don’t think we can afford to change anything.
   
   cc @yuqian90 maybe you could recall some of the context here?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] raphaelauv edited a comment on issue #17012: NONE_FAILED_OR_SKIPPED and NONE_FAILED do the same

Posted by GitBox <gi...@apache.org>.
raphaelauv edited a comment on issue #17012:
URL: https://github.com/apache/airflow/issues/17012#issuecomment-886526633


   @uranusjr thanks for the explanation.
   
   So we could maybe rename **NONE_FAILED_OR_SKIPPED** by **NONE_FAILED_AND_NONE_SKIPPED** ?
   
   That would be more explicit.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] yuqian90 commented on issue #17012: NONE_FAILED_OR_SKIPPED and NONE_FAILED do the same

Posted by GitBox <gi...@apache.org>.
yuqian90 commented on issue #17012:
URL: https://github.com/apache/airflow/issues/17012#issuecomment-883089001


   @uranusjr already explained the differences between these states. I just want to re-iterate that `none_failed_or_skipped` and `none_failed` are different. The difference is explained in [Trigger Rules](https://airflow.apache.org/docs/apache-airflow/stable/concepts/dags.html#trigger-rules).
   
   In the documented example, if `join` is set to `none_failed_or_skipped`, it is skipped when both `branch_false` and `follow_branch_a` are skipped. However, if `join` is set to `none_failed`, it will be `success` even if both `branch_false` and `follow_branch_a` are skipped.
   ![image](https://user-images.githubusercontent.com/6637585/126268585-a4ac658e-95f9-4b55-a5ed-097a8cb5c66b.png)
   
   In practices, I do find the `none_failed_or_skipped` behaviour more useful, especially when used to join branching logic. However, I don't know if any users out there prefer the behaviour of `none_failed`.
   
   The code that causes such difference can be found here:
   https://github.com/apache/airflow/blob/866a601b76e219b3c043e1dbbc8fb22300866351/airflow/ti_deps/deps/trigger_rule_dep.py#L146


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] raphaelauv edited a comment on issue #17012: NONE_FAILED_OR_SKIPPED is unclear

Posted by GitBox <gi...@apache.org>.
raphaelauv edited a comment on issue #17012:
URL: https://github.com/apache/airflow/issues/17012#issuecomment-886526633


   @uranusjr thanks for the explanation.
   
   So we could maybe rename **NONE_FAILED_OR_SKIPPED** by **NONE_FAILED_AND_AT_LEAST_ONE_SUCCES** ?
   
   That would be more explicit.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] uranusjr edited a comment on issue #17012: NONE_FAILED_OR_SKIPPED and NONE_FAILED do the same

Posted by GitBox <gi...@apache.org>.
uranusjr edited a comment on issue #17012:
URL: https://github.com/apache/airflow/issues/17012#issuecomment-882907844


   I `git blame`-ed this and `NONE_FAILED_OR_SKIPPED` was added in #7464. `NONE_FAILED_OR_SKIPPED` is intentionally implemented to be almost exactly the same as `NONE_FAILED`, but sets the state of the *current* task differently.
   
   https://github.com/apache/airflow/blob/16c55f100374df8cb17a85d06396aa42785fed0e/airflow/ti_deps/deps/trigger_rule_dep.py#L128-L156
   
   Assuming no upstream fails…
   
   * `ALL_SUCCESS` skips the current task if at least one upstream is skipped.
   * `NONE_FAILED` does nothing (continues the current task).
   * `NONE_FAILED_OR_SKIPPED` skips the current task only if *all* upstream tasks are skipped, otherwise continues.
   
   So I don’t think we can afford to change anything (although from the discussion in #7464 maybe we could deprecate `NONE_FAILED`).
   
   cc @yuqian90 maybe you could recall some of the context here?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] eladkal commented on issue #17012: NONE_FAILED_OR_SKIPPED is unclear

Posted by GitBox <gi...@apache.org>.
eladkal commented on issue #17012:
URL: https://github.com/apache/airflow/issues/17012#issuecomment-894757833


   > At first I through it was a redondant trigger_rule, but now I'm just proposing a more explicit name , but nothing really important. I will close the issue in the next days if it's not relevant.
   
   Do you have suggestion for a better name?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] raphaelauv commented on issue #17012: NONE_FAILED_OR_SKIPPED is unclear

Posted by GitBox <gi...@apache.org>.
raphaelauv commented on issue #17012:
URL: https://github.com/apache/airflow/issues/17012#issuecomment-894760493


   You missed my previous messages, take a look


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] raphaelauv edited a comment on issue #17012: NONE_FAILED_OR_SKIPPED is unclear

Posted by GitBox <gi...@apache.org>.
raphaelauv edited a comment on issue #17012:
URL: https://github.com/apache/airflow/issues/17012#issuecomment-886526633


   @uranusjr thanks for the explanation.
   
   So we could maybe rename **NONE_FAILED_OR_SKIPPED** by **NONE_FAILED_AND_AT_LEAST_ONE_SUCCEED** ?
   
   That would be more explicit.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] raphaelauv edited a comment on issue #17012: NONE_FAILED_OR_SKIPPED and NONE_FAILED do the same

Posted by GitBox <gi...@apache.org>.
raphaelauv edited a comment on issue #17012:
URL: https://github.com/apache/airflow/issues/17012#issuecomment-886526633


   @uranusjr thanks for the explanation.
   
   So we could maybe rename **NONE_FAILED_OR_SKIPPED** by **NONE_FAILED_OR_NOT_ALL_SKIPPED** ?
   
   That would be more explicit.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] raphaelauv commented on issue #17012: NONE_FAILED_OR_SKIPPED is unclear

Posted by GitBox <gi...@apache.org>.
raphaelauv commented on issue #17012:
URL: https://github.com/apache/airflow/issues/17012#issuecomment-894706696


   At first I through it was a redondant trigger_rule, but now I'm just proposing a more explicit name , but nothing really important. I will close the issue in the next days if it's not relevant.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] raphaelauv edited a comment on issue #17012: NONE_FAILED_OR_SKIPPED is unclear

Posted by GitBox <gi...@apache.org>.
raphaelauv edited a comment on issue #17012:
URL: https://github.com/apache/airflow/issues/17012#issuecomment-886526633


   @uranusjr thanks for the explanation.
   
   So we could maybe rename **NONE_FAILED_OR_SKIPPED** by **NONE_FAILED_OR_ALL_SKIPPED** ?
   
   That would be more explicit.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] uranusjr edited a comment on issue #17012: NONE_FAILED_OR_SKIPPED and NONE_FAILED do the same

Posted by GitBox <gi...@apache.org>.
uranusjr edited a comment on issue #17012:
URL: https://github.com/apache/airflow/issues/17012#issuecomment-882907844


   I `git blame`-ed this and `NONE_FAILED_OR_SKIPPED` was added in #7464 to resolve [AIRFLOW-4453]. `NONE_FAILED_OR_SKIPPED` is intentionally implemented to be almost exactly the same as `NONE_FAILED`, but sets the state of the *current* task differently.
   
   https://github.com/apache/airflow/blob/16c55f100374df8cb17a85d06396aa42785fed0e/airflow/ti_deps/deps/trigger_rule_dep.py#L128-L156
   
   Assuming no upstream fails…
   
   * `ALL_SUCCESS` skips the current task if at least one upstream is skipped.
   * `NONE_FAILED` does nothing (continues the current task).
   * `NONE_FAILED_OR_SKIPPED` skips the current task only if *all* upstream tasks are skipped, otherwise continues.
   
   So I don’t think we can afford to change anything (although from the discussion in [AIRFLOW-4453], maybe we could deprecate `NONE_FAILED_OR_SKIPPED` since its use case is mainly for backward compatibility and does not really make sense).
   
   cc @yuqian90 maybe you could recall some of the context here?
   
   [AIRFLOW-4453]: https://issues.apache.org/jira/browse/AIRFLOW-4453


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] potiuk commented on issue #17012: NONE_FAILED_OR_SKIPPED and NONE_FAILED do the same

Posted by GitBox <gi...@apache.org>.
potiuk commented on issue #17012:
URL: https://github.com/apache/airflow/issues/17012#issuecomment-882808812


   Looks about right. For the sake of backwards compatibility I'd merge it in one IF and deprecate one of those. Anyone?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] uranusjr commented on issue #17012: NONE_FAILED_OR_SKIPPED and NONE_FAILED do the same

Posted by GitBox <gi...@apache.org>.
uranusjr commented on issue #17012:
URL: https://github.com/apache/airflow/issues/17012#issuecomment-890292670


   “Trigger this task if none (of the upstreams) failed or [were] skipped” reads reasonable to me, so IMO a rename is not necessary. But English is hard and also not my first langauge, so don’t take my word for this 🙂 


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] raphaelauv edited a comment on issue #17012: NONE_FAILED_OR_SKIPPED and NONE_FAILED do the same

Posted by GitBox <gi...@apache.org>.
raphaelauv edited a comment on issue #17012:
URL: https://github.com/apache/airflow/issues/17012#issuecomment-886526633


   @uranusjr thanks for the explanation.
   
   So we could maybe rename **NONE_FAILED_OR_SKIPPED** by **NONE_FAILED_OR_ALL_SKIPPED** ?
   
   That would be more explicit.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] uranusjr commented on issue #17012: NONE_FAILED_OR_SKIPPED and NONE_FAILED do the same

Posted by GitBox <gi...@apache.org>.
uranusjr commented on issue #17012:
URL: https://github.com/apache/airflow/issues/17012#issuecomment-882907844


   I `git blame`-ed this and `NONE_FAILED_OR_SKIPPED` was added in #7464. `NONE_FAILED_OR_SKIPPED` is intentionally implemented to be almost exactly the same as `NONE_FAILED`, but sets the state of the *current* task differently.
   
   https://github.com/apache/airflow/blob/16c55f100374df8cb17a85d06396aa42785fed0e/airflow/ti_deps/deps/trigger_rule_dep.py#L128-L156
   
   Assuming no upstream fails…
   
   * `ALL_SUCCESS` skips the current task if at least one upstream is skipped.
   * `NONE_FAILED` does nothing (continues the current task).
   * `NONE_FAILED_OR_SKIPPED` skips the current task only if *all* upstream tasks are skipped, otherwise continues.
   
   So I don’t think we can afford to change anything.
   
   cc @yuqian90 maybe you could recall some of the context here?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] potiuk commented on issue #17012: NONE_FAILED_OR_SKIPPED and NONE_FAILED do the same

Posted by GitBox <gi...@apache.org>.
potiuk commented on issue #17012:
URL: https://github.com/apache/airflow/issues/17012#issuecomment-882808812


   Looks about right. For the sake of backwards compatibility I'd merge it in one IF and deprecate one of those. Anyone?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] yuqian90 commented on issue #17012: NONE_FAILED_OR_SKIPPED and NONE_FAILED do the same

Posted by GitBox <gi...@apache.org>.
yuqian90 commented on issue #17012:
URL: https://github.com/apache/airflow/issues/17012#issuecomment-883089001


   @uranusjr already explained the differences between these states. I just want to re-iterate that `none_failed_or_skipped` and `none_failed` are different. The difference is explained in [Trigger Rules](https://airflow.apache.org/docs/apache-airflow/stable/concepts/dags.html#trigger-rules).
   
   In the documented example, if `join` is set to `none_failed_or_skipped`, it is skipped when both `branch_false` and `follow_branch_a` are skipped. However, if `join` is set to `none_failed`, it will be `success` even if both `branch_false` and `follow_branch_a` are skipped.
   ![image](https://user-images.githubusercontent.com/6637585/126268585-a4ac658e-95f9-4b55-a5ed-097a8cb5c66b.png)
   
   In practices, I do find the `none_failed_or_skipped` behaviour more useful, especially when used to join branching logic. However, I don't know if any users out there prefer the behaviour of `none_failed`.
   
   The code that causes such difference can be found here:
   https://github.com/apache/airflow/blob/866a601b76e219b3c043e1dbbc8fb22300866351/airflow/ti_deps/deps/trigger_rule_dep.py#L146


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] eladkal commented on issue #17012: NONE_FAILED_OR_SKIPPED is unclear

Posted by GitBox <gi...@apache.org>.
eladkal commented on issue #17012:
URL: https://github.com/apache/airflow/issues/17012#issuecomment-901116949


   @raphaelauv if you want to take it and run your suggestion in the mailing list and if accepted to open a PR you are more than welcome.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org