cuddly-jelly-27016
10/22/2024, 11:01 PM@task(container_image=image)
def task_1(in1: int) -> typing.List[int]:
return list(range(max(2, in1)))
@task(container_image=image)
def task_2(in1: int, in2: typing.List[int]) -> int:
return in1 + sum(in2)
@workflow
def my_wf(in1: int, in2: int) -> int:
a = task_1(in1=in1)
a1 = a[0]
a2 = a[1]
return task_2(in1=5, in2=[a1, a2, in2])
Here, in2 of the input task_2 will be a list of Promise, and promise::_translate_inputs_to_literals will transform it to Literal (LiteralCollection in this case). However, it didn't try to resolve the attribute path of the Promises inside the list. Therefore, this error is received:
image
This is just an example of a List of Promises. There should be a similar error with Dictionary and Tuple (Tuple is currently under development).
Expected behavior
It should be supported.
Additional context to reproduce
No response
Screenshots
No response
Are you sure this issue hasn't been raised already?
• Yes
Have you read the Code of Conduct?
• Yes
flyteorg/flytecuddly-jelly-27016
10/22/2024, 11:01 PM