kaxil commented on a change in pull request #8962:
URL: https://github.com/apache/airflow/pull/8962#discussion_r439038525
##########
File path: airflow/operators/python.py
##########
@@ -145,6 +149,145 @@ def execute_callable(self):
return self.python_callable(*self.op_args, **self.op_kwargs)
+class _PythonFunctionalOperator(BaseOperator):
+ """
+ Wraps a Python callable and captures args/kwargs when called for execution.
+
+ :param python_callable: A reference to an object that is callable
+ :type python_callable: python callable
+ :param op_kwargs: a dictionary of keyword arguments that will get unpacked
+ in your function
+ :type op_kwargs: dict (templated)
+ :param op_args: a list of positional arguments that will get unpacked when
+ calling your callable
+ :type op_args: list (templated)
+ :param multiple_outputs: if set, function return value will be
+ unrolled to multiple XCom values. Dict will unroll to xcom values with
keys as keys.
+ Defaults to False.
+ :type multiple_outputs: bool
+ """
+
+ template_fields = ('op_args', 'op_kwargs')
+ ui_color = PythonOperator. ui_color
Review comment:
```suggestion
ui_color = PythonOperator.ui_color
```
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]