Skip to content

Commit

Permalink
use apped instead of remove
Browse files Browse the repository at this point in the history
  • Loading branch information
Min Shi committed Mar 27, 2024
1 parent 220ffdd commit e37d15c
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions src/promptflow/promptflow/batch/_batch_engine.py
Original file line number Diff line number Diff line change
Expand Up @@ -252,9 +252,12 @@ def _copy_previous_run_result(

# Load previous node run info and remove aggregation nodes in case it is loaded into node run info
previous_node_run_infos = resume_from_run_storage.load_node_run_info_for_line(i)
for node_run_info in previous_node_run_infos:
if node_run_info.node in aggregation_nodes:
previous_node_run_infos.remove(node_run_info)
if aggregation_nodes:
previous_node_run_infos = [
node_run_info
for node_run_info in previous_node_run_infos
if node_run_info.node not in aggregation_nodes
]
previous_node_run_infos_dict = {node_run.node: node_run for node_run in previous_node_run_infos}
previous_node_run_outputs = {
node_info.node: node_info.output for node_info in previous_node_run_infos
Expand Down

0 comments on commit e37d15c

Please sign in to comment.