8679 Commits

Author SHA1 Message Date
Saurav Panda d12f2ee160 pin all dependency version in pyproject.toml (#4215)
<!-- This is an auto-generated description by cubic. -->
## Summary by cubic
Pinned all runtime, optional, and dev dependencies in pyproject.toml to
exact versions for deterministic installs and reproducible builds. Bumps
package version to 0.12.0.

- **Dependencies**
- Replaced version ranges with exact pins across core packages (e.g.,
pydantic 2.12.5, requests 2.32.5, openai 2.16.0, anthropic 0.76.0,
google-api-python-client 2.188.0).
- Pinned optional extras (cli, code, aws, oci, video, examples, eval) to
exact versions.
- Pinned dev tooling (ruff, pytest, fastapi, uvicorn, pre-commit, etc.)
to exact versions.
- Kept platform-specific markers (pyobjc on macOS, screeninfo on
non-macOS).

<sup>Written for commit a2f6be18fc.
Summary will update on new commits.</sup>

<!-- End of auto-generated description by cubic. -->
0.12.0
2026-02-25 17:09:16 -08:00
Saurav Panda a2f6be18fc pin all dependency version in pyproject.toml 2026-02-25 16:52:21 -08:00
Saurav Panda 39999813d2 improved csv file generation (#4213)
<!-- This is an auto-generated description by cubic. -->
## Summary by cubic
Automatically normalizes CSV content in the agent filesystem to produce
RFC 4180-compliant files on write and append. Fixes common LLM CSV
errors and handles double-escaped \n and \" outputs.

- **New Features**
- CsvFile now parses and re-serializes CSV via Python’s csv module to
fix quoting, escaping, empty fields, and blank lines.
- Detects and unescapes double-escaped \n and \" when no real newlines
exist; preserves literals when real newlines are present.
- Normalization applied on write and append with safe newline merging;
added example script and extensive tests.

- **Refactors**
  - Fixed code styling; pinned browser-use-sdk to 2.0.15.

<sup>Written for commit 4a70f0e64a.
Summary will update on new commits.</sup>

<!-- End of auto-generated description by cubic. -->
2026-02-25 15:25:42 -08:00
Saurav Panda 4a70f0e64a updated version of browser-use-sdk 2026-02-25 15:13:09 -08:00
Saurav Panda 2552caeca4 fixed code styling issue 2026-02-25 12:26:10 -08:00
Saurav Panda 8270346ccf improved csv file generation 2026-02-25 11:45:05 -08:00
Saurav Panda 943c93ab5d new version 0.11.13 (#4207)
<!-- This is an auto-generated description by cubic. -->
## Summary by cubic
Bump package version to 0.11.13 in pyproject.toml to release the next
patch.

<sup>Written for commit 1ed90b8bff.
Summary will update on new commits.</sup>

<!-- End of auto-generated description by cubic. -->
0.11.13
2026-02-24 21:18:38 -08:00
Saurav Panda 1ed90b8bff new version 0.11.13 2026-02-24 21:08:10 -08:00
Saurav Panda 32ae93b1fc Add save_as_pdf agent action for CDP-based page-to-PDF export (#4205)
<!-- This is an auto-generated description by cubic. -->
## Summary by cubic
Adds a new save_as_pdf agent action to export the current page to a PDF
via Chrome DevTools Protocol. Saves full-page content and returns the
file path; supports custom filename, paper size, orientation, scale, and
background.

- New Features
- Added SaveAsPdfAction with fields: file_name, print_background
(default true), landscape, scale (0.1–2.0), paper_format (Letter, Legal,
A4, A3, Tabloid).
- Integrated CDP Page.printToPDF with preferCSSPageSize and a 30s
timeout.
- Auto filename from page title, sanitized with .pdf added; duplicates
resolved by appending “(n)”.
- ActionResult includes a success message, the PDF path in attachments,
and the full path in long_term_memory.
- Added example script (examples/features/save_as_pdf.py) and CI tests
covering default/custom filenames, duplicates, A4 and landscape,
background rendering, and PDF validity.

<sup>Written for commit bc5659e7b4.
Summary will update on new commits.</sup>

<!-- End of auto-generated description by cubic. -->
2026-02-24 19:21:33 -08:00
Saurav Panda bc5659e7b4 Merge branch 'main' into add-feature-for-page-to-pdf 2026-02-24 18:41:57 -08:00
Saurav Panda 95215d6211 Add save_as_pdf agent action for CDP-based page-to-PDF export 2026-02-24 18:35:34 -08:00
Larsen Cundrič d0a650a9fb Add timeouts to browser connects and waits (#4204) 2026-02-24 18:21:04 -08:00
Larsen Cundrič 2503c5f159 Merge branch 'main' into larsen/add-timeouts-to-browser-connects 2026-02-24 18:19:42 -08:00
LarsenCundric 505d5df406 Add timeouts to browser connects and waits 2026-02-24 18:13:28 -08:00
Saurav Panda 877159bf38 Add WebSocket reconnection for remote browser CDP connections (#4160)
<!-- This is an auto-generated description by cubic. -->
## Summary by cubic
Add automatic WebSocket reconnection for remote CDP connections so
agents recover from transient drops without stopping. Adds reconnect
events, fixes timeouts, and updates error handling and watchdogs to wait
for recovery instead of failing.

- **New Features**
- Auto-reconnect CDP WebSocket with up to 3 attempts (1s, 2s, 4s
backoff); detects WS drops from the CDP message handler and triggers
reconnect.
- Reconnect rebuilds the CDP client/session manager, re-enables
autoAttach, restores page focus (fallback or new blank page), and proxy
auth.
- Emits BrowserReconnectingEvent and BrowserReconnectedEvent (includes
attempt and downtime); emits BrowserErrorEvent on repeated failure.

- **Bug Fixes**
- Distinguish recoverable connection-like errors from true
browser-closed or intentional stops; suppress auto-reconnect on
kill/stop/reset.
- Standardize reconnection wait to RECONNECT_WAIT_TIMEOUT (54s) so
watchdogs and the step error handler wait the full window and resume on
success.
- Avoid false positives during reconnects by not treating transient CDP
None states as terminal; watchdogs now wait during reconnect instead of
skipping.

<sup>Written for commit 08bf06f734.
Summary will update on new commits.</sup>

<!-- End of auto-generated description by cubic. -->
2026-02-24 18:11:23 -08:00
Saurav Panda 08bf06f734 Merge branch 'main' into websocket-connection-issues 2026-02-24 17:18:33 -08:00
Saurav Panda 94ae0f8f39 feat: added automatic captcha solver handling via CAPTCHA watchdog (#4155)
<!-- This is an auto-generated description by cubic. -->
## Summary by cubic
Adds automatic CAPTCHA handling that pauses agent steps while the
browser solves challenges, then resumes and reports the result to the
model. Prompts now say CAPTCHAs are auto-solved.

- New Features
- CaptchaWatchdog listens for typed
BrowserUse.captchaSolverStarted/Finished events, waits until done (with
timeout), and exposes session.wait_if_captcha_solving returning a typed
CaptchaWaitResult.
- Agent step pre-checks for active CAPTCHA, waits, resets timing, and
appends an ActionResult with vendor, duration, and outcome.
- Emits typed CaptchaSolverStarted/Finished events; handlers auto-attach
on connect and clear on disconnect, with duplicate-attach protection.
New BrowserProfile.captcha_solver flag (default true).

- Dependencies
  - Bumped cdp-use to 1.4.5 for CAPTCHA solver events.

<sup>Written for commit f60a62bc76.
Summary will update on new commits.</sup>

<!-- End of auto-generated description by cubic. -->
2026-02-24 08:54:12 -08:00
Aitor f60a62bc76 Merge branch 'main' into feat/add-captcha-solver-handling 2026-02-24 07:13:06 +01:00
Saurav Panda 719d0361e5 Fix reconnection wait timeout to cover full auto-reconnect window
The circuit breaker and agent error handler were using a hardcoded 20s
timeout, but the worst-case auto-reconnect window is ~48s (3 attempts *
15s + 7s delays). Handlers would raise ConnectionError while reconnection
was still in progress. Now both use BrowserSession.RECONNECT_WAIT_TIMEOUT
(54s) derived from the actual reconnect parameters.
2026-02-23 17:47:52 -08:00
Saurav Panda 032f1475cb Merge branch 'main' into websocket-connection-issues 2026-02-23 17:44:17 -08:00
Saurav Panda 6959198fb2 fix radio button click occlusion when label overlaps input (#4157)
<!-- This is an auto-generated description by cubic. -->
## Summary by cubic
Fixes radio button clicks when a label overlaps the input by updating
the occlusion check to recognize label↔input associations. Adds
CI-friendly deterministic tests for sibling, wrapped, custom-styled
radios, and group switching; removes the flaky HTML fixture and the old
agent-based test. Addresses the radio button interaction issue noted in
Linear.

- **Bug Fixes**
- Treat label-input associations as clickable in the occlusion check:
label[for]→input, label wrapping input, and label↔input hit cases.
- Ensure clicks work when labels occlude inputs, including
CSS-customized radios; tests now use Tools.click with CDP assertions,
cover group switching, and drop the flaky HTML fixture.

<sup>Written for commit de8039288d.
Summary will update on new commits.</sup>

<!-- End of auto-generated description by cubic. -->
2026-02-23 17:40:26 -08:00
Aitor c0528bec2d Merge branch 'main' into feat/add-captcha-solver-handling 2026-02-24 02:19:25 +01:00
Saurav Panda ea23b45daa Merge branch 'main' into websocket-connection-issues 2026-02-23 17:14:57 -08:00
Saurav Panda de8039288d Merge branch 'main' into browser-use-radio-button-interaction-issue 2026-02-23 16:55:36 -08:00
Saurav Panda abd0326a6f Add WebSocket reconnection for remote browser CDP connections 2026-02-23 16:34:21 -08:00
Saurav Panda 84babc6b75 fix radio button click occlusion when label overlaps input 2026-02-23 16:19:05 -08:00
Saurav Panda 4cfc1d2802 updated _navigate_and_wait (#4146)
<!-- This is an auto-generated description by cubic. -->
## Summary by cubic
Make navigation resilient on slow or heavy pages and redirect chains.
Respects wait_until, adds a 20s guard on Page.navigate to prevent hangs,
and bumps NavigateToUrlEvent timeout to 30s.

- **Bug Fixes**
- _navigate_and_wait accepts wait_until ('commit', 'domcontentloaded',
'load', 'networkidle') and returns on that signal.
- Wrapped Page.navigate with a 20s timeout; raises RuntimeError on
timeout.
  - Increased NavigateToUrlEvent default timeout from 15s to 30s.
- Added CI tests for slow servers, redirect chains, DOMContentLoaded
acceptance, recovery after slow nav, and timeout correctness.

- **Dependencies**
  - Set pre-commit default Python to 3.11.
  - Lint workflow pins Python 3.11 and syncs with --python 3.11.

<sup>Written for commit 6c984ad02b.
Summary will update on new commits.</sup>

<!-- End of auto-generated description by cubic. -->
2026-02-23 16:08:47 -08:00
Saurav Panda 6c984ad02b install python version in lint.yml 2026-02-23 16:05:06 -08:00
Saurav Panda 3d174998e4 Merge branch 'main' into navigation-issues 2026-02-23 15:43:23 -08:00
Saurav Panda e50588f3c7 fixed styling issues 2026-02-23 15:24:40 -08:00
reformedot 45e9a6cea3 chore: linting 2026-02-23 11:03:14 -08:00
reformedot bbad1548d7 Merge branch 'feat/add-captcha-solver-handling' of github.com:browser-use/browser-use into feat/add-captcha-solver-handling 2026-02-23 10:57:56 -08:00
reformedot b4058359a9 refactor: enhance CaptchaWatchdog with typed event handling and result types
- Introduced type aliases for captcha results to improve clarity and maintainability.
- Updated event handler signatures to use specific event types from the CDP module.
- Ensured consistent typing for captcha result attributes within the CaptchaWaitResult class.
- Added assertion for timeout handling in the captcha waiting logic.
2026-02-23 10:57:48 -08:00
Aitor 973b6c5c4b Merge branch 'main' into feat/add-captcha-solver-handling 2026-02-23 19:51:48 +01:00
reformedot ed28e50806 feat: added automatic captcha solver handling via CAPTCHA watchdog 2026-02-23 10:51:02 -08:00
Saurav Panda 774e83843e updated laminar version (#4154)
<!-- This is an auto-generated description by cubic. -->
## Summary by cubic
Upgraded Laminar (lmnr) to 0.7.42 in eval and dev environments to pick
up recent fixes and improvements. This keeps our tooling and evaluation
stack aligned on the same version.

- **Dependencies**
- pyproject.toml: bump lmnr[all] from 0.7.17 to 0.7.42 in eval and
dev-dependencies.

<sup>Written for commit e3d63c0e13.
Summary will update on new commits.</sup>

<!-- End of auto-generated description by cubic. -->
2026-02-23 10:38:59 -08:00
Saurav Panda e3d63c0e13 updated laminar version 2026-02-23 10:28:55 -08:00
Magnus Müller 1d154e11f9 Add legal links to telemetry docs and PyPI metadata (#4147)
## Summary
- update telemetry runtime log message to the canonical monitoring
telemetry docs URL
- add Terms of Service and Privacy Policy links on the telemetry docs
page
- expose Homepage, Documentation, Telemetry, Terms of Service, and
Privacy Policy under `project.urls` for PyPI
- add a short legal-links notice in the README (used as PyPI long
description)

## Why
- make telemetry/legal references easier to find from logs, docs, and
PyPI
- align package-facing surfaces with legal-link guidance from counsel

## Testing
- pre-commit hooks pass on commit

<!-- This is an auto-generated description by cubic. -->
---
## Summary by cubic
Add ToS/Privacy links to the telemetry docs and simplify the README
legal FAQ to a generic services data policy; update the telemetry
startup log to the canonical monitoring docs URL.
Expose Homepage, Docs, Telemetry, ToS, and Privacy links in PyPI
project.urls and bump version to 0.11.12.

<sup>Written for commit afd17cf318.
Summary will update on new commits.</sup>

<!-- End of auto-generated description by cubic. -->

<!-- CURSOR_SUMMARY -->
---

> [!NOTE]
> **Low Risk**
> Documentation/metadata-only changes plus a log-message URL update; no
runtime behavior or data handling changes.
> 
> **Overview**
> Updates public-facing references for telemetry and legal policies. The
telemetry startup log now points to the canonical docs URL, the
telemetry docs add a **Legal** section linking Terms of Service and
Privacy Policy, and the README FAQ adds a ToS blurb for the hosted
services.
> 
> Also bumps the package version to `0.11.12` and expands
`pyproject.toml` `project.urls` (Homepage/Docs/Telemetry/ToS/Privacy) so
these links show up in PyPI metadata.
> 
> <sup>Written by [Cursor
Bugbot](https://cursor.com/dashboard?tab=bugbot) for commit
cf1b003ba0. This will update automatically
on new commits. Configure
[here](https://cursor.com/dashboard?tab=bugbot).</sup>
<!-- /CURSOR_SUMMARY -->
0.11.12
2026-02-22 20:35:23 -08:00
Magnus Müller cf1b003ba0 Update summary for legal terms section in README 2026-02-22 20:34:05 -08:00
Magnus Müller afd17cf318 Simplify FAQ legal wording to generic services data policy 2026-02-22 20:30:57 -08:00
Magnus Müller cc03bb647e Move legal note into FAQ and remove footer text 2026-02-22 20:28:48 -08:00
Magnus Müller a052cb46db Move README legal note to footer and bump version 2026-02-22 20:26:33 -08:00
Magnus Müller de0215c0df Add legal links to telemetry docs and package metadata 2026-02-22 20:08:09 -08:00
Saurav Panda 6713afc636 updated _navigate_and_wait 2026-02-21 19:45:54 -08:00
Saurav Panda 3d7c71f4a6 remove simple judge (#4144)
<!-- This is an auto-generated description by cubic. -->
## Summary by cubic
Removed the lightweight “simple judge” that auto-validated agent success
to simplify the flow and reduce LLM calls. The agent now relies only on
the full judge when enabled, with no automatic success overrides.

- **Refactors**
- Removed construct_simple_judge_messages, SimpleJudgeResult, and
_run_simple_judge.
- Deleted simple judge imports and calls from service (including
take_step/_execute_step); full judge path remains unchanged.
  - Cleaned unused imports and fixed ruff formatting in modified files.

- **Migration**
- Remove any imports/usages of SimpleJudgeResult or simple judge
messages/hooks and use the full judge or custom validation instead.
- Outputs will no longer include “[Simple judge: …]” notes in
extracted_content or metadata.

<sup>Written for commit 2c878aa75c.
Summary will update on new commits.</sup>

<!-- End of auto-generated description by cubic. -->
2026-02-21 09:49:39 -08:00
Saurav Panda 2c878aa75c Merge branch 'main' into remove-simple-judge 2026-02-21 09:46:28 -08:00
Saurav Panda adf3bf9f43 fixed ruff formatting issues 2026-02-21 09:42:20 -08:00
Magnus Müller 1c58c736a3 Browser agent setup (#4139)
Re-add browser initialization and passing to the agent in the README
quickstart example.

---
[Slack
Thread](https://browser-use.slack.com/archives/C08SZRT860M/p1771645267295089?thread_ts=1771645267.295089&cid=C08SZRT860M)

<p><a
href="https://cursor.com/agents?id=bc-bebbe1a3-5ea1-5d52-afc5-aeeeb3df96d4"><picture><source
media="(prefers-color-scheme: dark)"
srcset="https://cursor.com/assets/images/open-in-web-dark.png"><source
media="(prefers-color-scheme: light)"
srcset="https://cursor.com/assets/images/open-in-web-light.png"><img
alt="Open in Web" width="114" height="28"
src="https://cursor.com/assets/images/open-in-web-dark.png"></picture></a>&nbsp;<a
href="https://cursor.com/background-agent?bcId=bc-bebbe1a3-5ea1-5d52-afc5-aeeeb3df96d4"><picture><source
media="(prefers-color-scheme: dark)"
srcset="https://cursor.com/assets/images/open-in-cursor-dark.png"><source
media="(prefers-color-scheme: light)"
srcset="https://cursor.com/assets/images/open-in-cursor-light.png"><img
alt="Open in Cursor" width="131" height="28"
src="https://cursor.com/assets/images/open-in-cursor-dark.png"></picture></a>&nbsp;</p>

<!-- This is an auto-generated description by cubic. -->
---
## Summary by cubic
Re-adds Browser initialization in the README quickstart and passes it to
Agent so the example runs correctly. Simplifies setup to a single
commented use_cloud option for Browser Use Cloud.

<sup>Written for commit db44fba80e.
Summary will update on new commits.</sup>

<!-- End of auto-generated description by cubic. -->
2026-02-21 00:36:43 -08:00
Cursor Agent db44fba80e Simplify Browser init to single commented use_cloud option
Co-authored-by: Magnus Müller <MagMueller@users.noreply.github.com>
2026-02-21 08:33:20 +00:00
Cursor Agent caf50d2f34 Add Browser initialization to README quickstart example
Co-authored-by: Magnus Müller <MagMueller@users.noreply.github.com>
2026-02-21 04:10:23 +00:00