- Applied automated linting suggestions from pre-commit hooks, primarily updating type hints (e.g., Dict -> dict) and organizing imports.
- Refactored Playwright script execution in examples/features/playwright_script_generation.py to use asyncio.create_subprocess_exec for asynchronous handling and real-time log streaming, resolving ASYNC221 lint error and improving output visibility.
Implement the ability to generate executable Playwright scripts from an Agent's run history (`AgentHistoryList`).
This introduces the `PlaywrightScriptGenerator` class which translates recorded agent actions (clicks, inputs, navigation, etc.) into a Python script using Playwright's async API.
Key features:
- Uses XPath selectors derived from the agent's interaction history.
- Includes a robust helper function (`_try_locate_and_act`) with XPath prefix trimming for improved resilience on dynamic pages.
- Handles sensitive data placeholders by mapping them to environment variables in the generated script.
- Supports configuring the browser launch and context based on the original agent's `BrowserConfig` and `BrowserContextConfig`.
- Activated by setting the `save_playwright_script_path` option in `AgentSettings`.
Includes modifications to `Agent` service to trigger generation and `AgentHistoryList` view to add the saving method. Also adds a new example (`examples/features/playwright_script_generation.py`).
This feature enables reliable replay of agent runs, automated testing, and scripting of repetitive tasks discovered by the agent.
* Add http_credentials to browser context.
* Detect index change caused by page change in `multi_act`
* Fix: Add sameSite cookie validation and auto-correction
* added drag drop action
* added drag drop action
* pre-commit run -a (again)
* added active_tab state management
* add anthropic RateLimitError to list of defined rate limit errors
* Add Retry handling to bedrock example
* fix pydantic issue causing config to be overwritten
* fix config setup
* Add botocore, organize imports
* ignore langchain beta warnings
* silence pydantic deprecation warnings
* Update bedrock_claude for ruff
* ruff checks
* Update pyproject.toml and bedrock_claude.py
* ignore signal registration errors in edge case environments
* ruff fixes
* add example of getting 2FA code from 1password
* add rebrowser and creepjs to stealth tests
* Fix typos discovered by codespell
* uv add --dev codespell
* Update browser_use/browser/context.py
* lint
* Add explanations override_system_message and extend_system_message
* Update custom-functions.mdx
.get_current_page() is an async function which have to be awaited.
* Fix: Remove unnecessary await from _verified_api_keys
* Fix: Correct indentation for cookie loading log message in BrowserContext
* Fix: resolve undefined response variable in Deepseek model raw tool calling mode
* fix: increment consecutive_failure on every step error
* Fix azure example not working due to agent memory changes
* dont expose debug port on all addresses and keep security enabled by default
* custom browser addition
---------
Co-authored-by: Bartlomiej Wietrak <bartekwietrak@gmail.com>
Co-authored-by: Alin Jiang <alineveryday@outlook.com>
Co-authored-by: dipfocus <dipfocus@gmail.com>
Co-authored-by: PaperBoardOfficial <hiremohitforsoftwarerole@gmail.com>
Co-authored-by: Christian Clauss <cclauss@me.com>
Co-authored-by: Alezander9 <alexander.j.yue@gmail.com>
Co-authored-by: dheerajoruganty <db2winfb@gmail.com>
Co-authored-by: Nick Sweeting <git@sweeting.me>
Co-authored-by: Dheeraj Oruganty <53569374+dheerajoruganty@users.noreply.github.com>
Co-authored-by: Bart <46058081+b0rgcube@users.noreply.github.com>
Co-authored-by: Nick Sweeting <github@sweeting.me>
Co-authored-by: pppp606 <ppppp303@gmail.com>
Co-authored-by: Oswy <74738120+oswy-cpu@users.noreply.github.com>
Co-authored-by: BurnyCoder <happymancz@email.cz>
Co-authored-by: zhushijie <mr.zhushijie@gmail.com>
Co-authored-by: john-rtr <jonathan.ratier@gmail.com>
Co-authored-by: mathisarends-viadee <mathis.arends@viadee.de>
Co-authored-by: lorenss-m <saeclmusic@gmail.com>
Co-authored-by: Magnus Müller <67061560+MagMueller@users.noreply.github.com>