Skip to content

fix(browser): allow explicit CDP override without local agent-browser dependency - #16070

Closed
xyiy001 wants to merge 1 commit into
NousResearch:mainfrom
xyiy001:fix/browser-cdp-checkfn
Closed

fix(browser): allow explicit CDP override without local agent-browser dependency#16070
xyiy001 wants to merge 1 commit into
NousResearch:mainfrom
xyiy001:fix/browser-cdp-checkfn

Conversation

@xyiy001

@xyiy001 xyiy001 commented Apr 26, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Treat explicit CDP override mode (BROWSER_CDP_URL) as a valid browser backend in check_browser_requirements().
  • Remove the false-negative availability gate that required a local agent-browser binary even when using direct CDP connection.
  • Add a regression test to lock this behavior and prevent future regressions.

Why

When users connect via explicit CDP endpoint, the local agent-browser CLI is not required for capability detection. The previous check incorrectly reported browser tools as unavailable, which blocked valid browser workflows.

Changes

  • Update tools/browser_tool.py:
    • check_browser_requirements() now returns success when CDP override is present.
  • Update tests/tools/test_browser_homebrew_paths.py:
    • Add test_cdp_override_does_not_require_agent_browser_cli.

Validation

  • git log main..HEAD --oneline contains only this task commit.
  • git diff main --stat includes only planned files.
  • Target regression test passed:
    • python -m pytest tests/tools/test_browser_homebrew_paths.py::TestBrowserRequirements::test_cdp_override_does_not_require_agent_browser_cli -q

Related Issue

@xyiy001
xyiy001 force-pushed the fix/browser-cdp-checkfn branch from 7f0ca26 to 7581dca Compare April 26, 2026 14:06
Treat explicit CDP override mode as a valid browser backend even when agent-browser is absent, and add a regression test to prevent false-negative availability gating.
@xyiy001
xyiy001 force-pushed the fix/browser-cdp-checkfn branch from 7581dca to bdc1db5 Compare April 26, 2026 14:06
@alt-glitch alt-glitch added type/bug Something isn't working P2 Medium — degraded but workaround exists tool/browser Browser automation (CDP, Playwright) labels Apr 26, 2026
@teknium1

teknium1 commented May 4, 2026

Copy link
Copy Markdown
Contributor

Salvaged via #19670 onto current main - your commit authorship was preserved. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

P2 Medium — degraded but workaround exists tool/browser Browser automation (CDP, Playwright) type/bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: browser-cdp check_fn unnecessarily requires agent-browser

3 participants