Open-source Python library for AI browser agents, plus Browser Use Cloud: stealth browsers and a hosted agent API.
Python ai-agentsai-toolsbrowser-agentbrowser-automationbrowser-usecdpcloud-browsercomputer-useheadless-browserllmmcpplaywrightpythonremote-browserstealth-browserweb-automationweb-scraping
Enhance agent stopping behavior
Magnus Müllerc7313d39e768
diff --git a/browser_use/agent/service.py b/browser_use/agent/service.pyindex c9e130c73..c5c867a87 100644--- a/browser_use/agent/service.py+++ b/browser_use/agent/service.py@@ -1938,6 +1938,9 @@ class Agent(Generic[Context, AgentStructuredOutput]):"""Stop the agent"""self.logger.info('⏹️ Agent stopping')self.state.stopped = True++ # Signal pause event to unblock any waiting code so it can check the stopped state+ self._external_pause_event.set()# Task stoppeddiff --git a/examples/file_system/file_system/fs/browseruse_agent_data/todo.md b/examples/file_system/file_system/fs/browseruse_agent_data/todo.mddeleted file mode 100644index e69de29bb..000000000