Jay Ganbat
04/03/2023, 11:17 PM@dataclass
@dataclass_json
class MyDataClass:
name: str
@task
def my_task() -> MyDataClass:
return MyDataclass object
@task
def another_task(name: str) -> str:
return f"Hello {name}"
@workflow
def my_wf() -> None:
result = my_task()
another_task(name=result.name)
when i try the above, it says 'Promise' object has no attribute 'name'
i just didnt wanna give the whole object to the task, i just want 1 field from it 😅Kevin Su
04/03/2023, 11:23 PMJay Ganbat
04/03/2023, 11:42 PMDan Rammer (hamersaw)
04/04/2023, 1:13 PMJay Ganbat
04/04/2023, 4:17 PM