File tree Expand file tree Collapse file tree 1 file changed +8
-2
lines changed
webqa_agent/testers/case_gen/agents Expand file tree Collapse file tree 1 file changed +8
-2
lines changed Original file line number Diff line number Diff line change @@ -574,13 +574,16 @@ def extract_path(u):
574574 )
575575 ]
576576 final_summary = "No summary provided."
577- total_steps = len (case .get ("steps" , []))
577+ case_steps = case .get ("steps" , []) # Get reference to steps list
578+ total_steps = len (case_steps )
578579 failed_steps = [] # Track failed steps for summary generation
579580 case_modified = False # Track if case was modified with dynamic steps
580581 dynamic_generation_count = 0 # Track how many times dynamic generation occurred
581582 dom_diff_cache = []
582583
583- for i , step in enumerate (case .get ("steps" , [])):
584+ i = 0
585+ while i < len (case_steps ):
586+ step = case_steps [i ]
584587 instruction_to_execute = step .get ("action" ) or step .get ("verify" )
585588 step_type = "Action" if step .get ("action" ) else "Assertion"
586589
@@ -841,6 +844,9 @@ def is_similar_step(step1: dict, step2: dict) -> bool:
841844 failed_steps .append (i + 1 )
842845 final_summary = f"FINAL_SUMMARY: Step '{ instruction_to_execute } ' raised an exception: { str (e )} "
843846 break
847+
848+ # Move to next step
849+ i += 1
844850
845851 # If the loop finishes without an early exit, generate a final summary
846852 if "FINAL_SUMMARY:" not in final_summary :
You can’t perform that action at this time.
0 commit comments