Skip to content

armgit / cua

Public Imported from GitHub
0

Scale computer-use 2.0 with open-source drivers, cross-OS sandboxes, and benchmarks for training, evaluation, and data generation.

Fixed agent stop

Dillon DuPont89deb8111fbb
diff --git a/examples/eval_examples.py b/examples/eval_examples.py
index 38d9cae8a3..b4b207b6eb 100644
--- a/examples/eval_examples.py
+++ b/examples/eval_examples.py
@@ -146,8 +146,10 @@ async def main():
# Safety check
if steps >= max_steps:
- print(f"❌ Failed: Reached maximum steps ({max_steps})")
- break
+ print(f"❌ Stopping agent: Reached maximum steps ({max_steps})")
+ agent._loop.cancel()
+
+ await asyncio.sleep(2) # Wait for recv to finish
# Check again
current_page = await get_current_wiki_page()