Skip to content

Improve error-handling and error messages in CDP Mode #4093

Closed

Description

@mdmintz

Improve error-handling and error messages in CDP Mode

There are a few areas that could use some improvement. Eg. timing, error messages, etc.

There's an X11 error message that could explain how to fix the situation better: That generally means Xvfb isn't installed on that Linux system, which can be fixed with sudo apt install -y xvfb.

There's an error message for not being able to connect to the browser in CDP Mode: That generally means that the browser isn't already installed on the system. Usually seen on Linux, where people might not realize that Chrome/Chromium doesn't always come preinstalled.

Using proxy with auth in CDP Mode can throw off the timing on some page loads, but that situation can be improved with some timing updates.

Looks like CDP.browser.grant_permissions() is deprecated. That should be replaced with CDP.browser.set_permission().

When calling sb.open(url) from UC Mode with proxy auth when not using CDP Mode, then CDP Mode should automatically be activated because only CDP Mode can provide the auth to proxies after Chrome 142 (unless using regular non-stealth mode).

And looks like the ad_block=True functionality is missing some coverage.

Activity

  1. self-assigned this
    on Nov 11, 2025
  2. mdmintz commented on Nov 11, 2025

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

Metadata

Metadata

Assignees

Labels

UC Mode / CDP ModeUndetected Chromedriver Mode / CDP ModeenhancementMaking things better

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions