prehistoric-carpenter-16793
09/26/2024, 4:07 PMdata = {
'column1': np.random.randint(0, 100, size=10),
'column2': np.random.rand(10),
'column3': np.random.choice(['A', 'B', 'C', 'D'], size=10)
}
df = pd.DataFrame(data)
inputs = {
"data_source_name": "dashboards-test",
"data_source_description": "test",
"df_input": df
}
workflow_name = (
"workflowname"
)
remote = FlyteRemote(config=Config.auto())
workflow = remote.fetch_workflow(
project="project",
domain="production",
name=workflow_name,
)
execution = remote.execute(workflow, inputs=inputs)
execution = remote.wait(execution)
But it fails on this line remote.execute(workflow, inputs=inputs)
with the error:
ValueError: Error encountered while executing 'load_data':
Failed to find a handler for <class
'flytekit.types.structured.structured_dataset.StructuredDataset'>, protocol
[flyte], fmt ['']
I am assuming that they problem is related to the dataframe but in the workflow's code I saw that it is also being passed a dataframe without any problem.
Any suggestion?tall-lock-23197
prehistoric-carpenter-16793
10/01/2024, 7:46 AM"df_input" : StructuredDataset(dataframe=df, file_format="")
prehistoric-carpenter-16793
10/01/2024, 7:46 AM