Diogo Munaro
12/17/2020, 11:38 PMStartFlowRun
, but I can't get results from that flow. Looking at the code, create_flow_run
ignores result arg: https://github.com/PrefectHQ/prefect/blob/96ef85470872593268c9498b57ac9f0b5a268e01/src/prefect/tasks/prefect/flow_run.py#L160
Do you know a way to get Flow results?
Here a test code:
from prefect.tasks.prefect import StartFlowRun
from prefect import Flow, task
from prefect.engine.results.local_result import LocalResult
graph_building = StartFlowRun(
flow_name="test_flow",
project_name="test_project",
wait=True,
result=LocalResult(".")
)
with Flow("Call Flow") as flow:
end_flow = graph_building()
state = flow.run()
state.result[endflow].result #nothing here
Dylan
Dylan
Dylan
Diogo Munaro
12/18/2020, 12:59 PMwait
argument said that if True, this task will wait until the flow run is complete, and then reflect the corresponding state as the state of this task.
, but state is not the same of the Flow triggeredDylan
Diogo Munaro
12/21/2020, 1:08 PMDylan
Diogo Munaro
12/21/2020, 8:47 PMDylan
Dylan
Diogo Munaro
12/23/2020, 12:02 AMwait
is always waiting task and returning result instead of task ID... Do you know something about that?Zanie
wait
as an argument to StartFlowRun
still?Diogo Munaro
12/23/2020, 12:30 PMfrom prefect.tasks.prefect import StartFlowRun
from prefect import Flow, task
graph_building = StartFlowRun(
flow_name="test_flow",
project_name="test_project",
wait=True
)
with Flow("Call Flow") as flow:
end_flow = graph_building()
state = flow.run()
state.result[endflow].result #nothing here
and
from prefect.tasks.prefect import StartFlowRun
from prefect import Flow, task
graph_building = StartFlowRun(
flow_name="test_flow",
project_name="test_project",
wait=False
)
with Flow("Call Flow") as flow:
end_flow = graph_building()
state = flow.run()
state.result[endflow].result #nothing here
I was expecting that second one should return only execution idDiogo Munaro
12/23/2020, 2:02 PM