Hello, I am having a hard time to pass optional in...
# flyte-support
s
Hello, I am having a hard time to pass optional input param to tasks. Ideally, I want the task either be passed the actual instance of the input param or None. So I have :
Copy code
from sklearn.preprocessing import OneHotEncoder
@task
def transform(
    encoder: Optional[OneHotEncoder] = None, ...
)
The workflow will do:
Copy code
return transform(
   encoder=None, ...
176 Views