I might be missing something, but is there a way t...
# ask-the-community
r
I might be missing something, but is there a way to pass multiple arguments to a map task (ie. if I have a list
[1,2,3]
, can I pass each item to a map task along with some other fixed inputs that are common across all tasks). All the examples in the docs only include tasks w/ a single argument Relatedly, is there a way to use a workflow as part of a map task (ie. map a sub-workflow over a sequence of inputs) Edit: guess not
Copy code
Map tasks only accept python function tasks with 0 or 1 inputs
Would there be interest in adding support for this? Or is the recommendation to just represent multiple arguments in a single dataclass/namedtuple
s
cc: @Eduardo Apolinario (eapolinario) @Yee
k
Ya this is actually a limitation of the flytekit api not the engine
There is an issue
Please upvote - we were thinking of a partial like support
r
@Ketan (kumare3) I can't find the issue, if you link it will upvote. Partial-like support would be very helpful
@Samhita Alla thank you for the link! I missed that earlier.
k
you are right, i did not find it too. I am not sure where it was lost. cc @Yee / @katrina do you know?
k
I would also be in favor of having the possibility to define default inputs to map tasks. Is there a plan of implementing this? A prepare_map_inputs task seems more like a workaround to me
k
It is you are right
Let’s get this as an issue, do you mind filing your thoughts
k
Late, but finally filed a feature request here: https://github.com/flyteorg/flyte/issues/3120!
235 Views