Przeglądaj źródła

fix: improve merge branch node ID checks in graph engine (#12128)

Signed-off-by: -LAN- <laipz8200@outlook.com>
tags/0.15.0
-LAN- 10 miesięcy temu
rodzic
commit
26b5680913
No account linked to committer's email address

+ 2
- 2
api/core/workflow/graph_engine/entities/graph.py Wyświetl plik

for (node_id, node_id2), branch_node_ids in duplicate_end_node_ids.items(): for (node_id, node_id2), branch_node_ids in duplicate_end_node_ids.items():
# check which node is after # check which node is after
if cls._is_node2_after_node1(node1_id=node_id, node2_id=node_id2, edge_mapping=edge_mapping): if cls._is_node2_after_node1(node1_id=node_id, node2_id=node_id2, edge_mapping=edge_mapping):
if node_id in merge_branch_node_ids:
if node_id in merge_branch_node_ids and node_id2 in merge_branch_node_ids:
del merge_branch_node_ids[node_id2] del merge_branch_node_ids[node_id2]
elif cls._is_node2_after_node1(node1_id=node_id2, node2_id=node_id, edge_mapping=edge_mapping): elif cls._is_node2_after_node1(node1_id=node_id2, node2_id=node_id, edge_mapping=edge_mapping):
if node_id2 in merge_branch_node_ids:
if node_id in merge_branch_node_ids and node_id2 in merge_branch_node_ids:
del merge_branch_node_ids[node_id] del merge_branch_node_ids[node_id]


branches_merge_node_ids: dict[str, str] = {} branches_merge_node_ids: dict[str, str] = {}

Ładowanie…
Anuluj
Zapisz