uranusjr commented on issue #23803:
URL: https://github.com/apache/airflow/issues/23803#issuecomment-1134107753
The main problem of using zipping against a classic operator class is not
really about the zip operation itself, but to unpack the zipped iterator (i.e.
the `arg1, arg2 = param` part). Even if you can produce a zip iterator (which
you already can), it’s still difficult to use the iterator against a classic
operator. I am yet to be able to come up with a reasonable API either;
instantiating a class instance is (kind of) fundamentally not straightforward
in a unctional programming context.
Note that you can also already kind of do this like below. There’re a lot of
caveats on calling `execute` directly, but it’s kind of doable. (Not that I
particularly recommend it though.)
```
@task
def run_task(param):
image, arguments = param
op = KubernetesPodOperator(task_id="my-task", image=image,
arguments=arguments, ...)
op.execute()
```
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]