refactor: Update Graph.from_payload to include flow name
This commit updates the `Graph.from_payload` method in the `endpoints.py` file to include the `flow_name` parameter. This change ensures that the `Graph` object is created with the correct flow name, which is necessary for proper functionality. By passing the `flow.name` value to the `Graph.from_payload` method, we ensure that the `graph` object is initialized correctly with the associated flow name. This improvement enhances the accuracy and reliability of the code.
This commit is contained in:
parent
f6cc61053a
commit
77b7d8d626
1 changed files with 1 additions and 1 deletions
|
|
@ -88,7 +88,7 @@ async def simple_run_flow(
|
|||
raise ValueError(f"Flow {flow_id_str} has no data")
|
||||
graph_data = flow.data.copy()
|
||||
graph_data = process_tweaks(graph_data, input_request.tweaks or {}, stream=stream)
|
||||
graph = Graph.from_payload(graph_data, flow_id=flow_id_str, user_id=str(user_id))
|
||||
graph = Graph.from_payload(graph_data, flow_id=flow_id_str, user_id=str(user_id), flow_name=flow.name)
|
||||
inputs = [
|
||||
InputValueRequest(components=[], input_value=input_request.input_value, type=input_request.input_type)
|
||||
]
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue