airflow.decorators.python
¶
Module Contents¶
Functions¶
|
Wraps a function into an Airflow operator. |
- airflow.decorators.python.python_task(python_callable=None, multiple_outputs=None, **kwargs)[source]¶
Wraps a function into an Airflow operator.
Accepts kwargs for operator kwarg. Can be reused in a single DAG.
- Parameters
python_callable (Callable | None) – Function to decorate
multiple_outputs (bool | None) – If set to True, the decorated function’s return value will be unrolled to multiple XCom values. Dict will unroll to XCom values with its keys as XCom keys. Defaults to False.