-
Notifications
You must be signed in to change notification settings - Fork 14.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add @task.short_circuit
TaskFlow decorator
#25752
Add @task.short_circuit
TaskFlow decorator
#25752
Conversation
0be9238
to
8b52ce8
Compare
8b52ce8
to
48e2d3f
Compare
A documentation should be added somewhere (docstring? TaskFlow howto?) to describe what returning True and False means. |
That's fair. I think updating the docs somewhere would be my preference. Maybe in the Python Operator how-tos doc? Side note, maybe we should add a TaskFlow Decorators section to the Python API Reference in a separate PR. WDYT? |
Sounds good.
Agree. Also - since some of the decorators are coming from the providers, we should add a section in https://airflow.apache.org/docs/apache-airflow-providers/core-extensions/index.html (I can add it and also refactor this page a bit as it is a bit too long now and I think we should make it more compact). How about also reversing (in separate PR) the "priority" of "classic" vs. "taskflow" approach ? I think we are quickly approaching the point where taskflow is generally recommended and "on-par" approach than Classic and we should promote it as "the" way of doing things while marking classic approach as somewhat (not entirely but somewhat) legacty. |
48e2d3f
to
7dcb794
Compare
Update the Python operator how-to doc with references to the new decorator. |
The test failures don't look related to this PR, but they do look to be resolved by reverting #26175 (at least locally). |
e490430
to
5ed5ca1
Compare
5ed5ca1
to
dc6e808
Compare
Mainly rebasing to pick up #26188 which should hopefully yield clean CI checks. |
To complete the "Python operator" set, this PR adds a TaskFlow decorator abstraction for the
ShortCircuitOperator
.TODO:
^ Add meaningful description above
Read the Pull Request Guidelines for more information.
In case of fundamental code changes, an Airflow Improvement Proposal (AIP) is needed.
In case of a new dependency, check compliance with the ASF 3rd Party License Policy.
In case of backwards incompatible changes please leave a note in a newsfragment file, named
{pr_number}.significant.rst
or{issue_number}.significant.rst
, in newsfragments.