Skip to content

Activating CDP Mode more than once for the same driver can lead to asyncio errors #3716

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
mdmintz opened this issue Apr 30, 2025 · 1 comment · Fixed by #3717
Closed

Activating CDP Mode more than once for the same driver can lead to asyncio errors #3716

mdmintz opened this issue Apr 30, 2025 · 1 comment · Fixed by #3717
Assignees
Labels
bug Uh oh... Something needs to be fixed UC Mode / CDP Mode Undetected Chromedriver Mode / CDP Mode

Comments

@mdmintz
Copy link
Member

mdmintz commented Apr 30, 2025

Activating CDP Mode more than once for the same driver can lead to asyncio errors

Here's an example that reproduces the issue:

import seleniumbase, platform, string
from seleniumbase import SB

letters = string.ascii_lowercase[0:2]
print(platform.python_version())
print(seleniumbase.__version__)

with SB(uc=True) as sb:
    for _id, letter in enumerate(letters):
        print(_id + 1, letter)
        sb.activate_cdp_mode()
        sb.connect()
        sb.open(f"data:text/html,<h1>Page {letter}</h1>")
        sb.assert_text(f"Page {letter}")
@mdmintz mdmintz added bug Uh oh... Something needs to be fixed UC Mode / CDP Mode Undetected Chromedriver Mode / CDP Mode labels Apr 30, 2025
@mdmintz mdmintz self-assigned this Apr 30, 2025
@mdmintz
Copy link
Member Author

mdmintz commented Apr 30, 2025

This was resolved in 4.37.11 - https://github.com/seleniumbase/SeleniumBase/releases/tag/v4.37.11

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Uh oh... Something needs to be fixed UC Mode / CDP Mode Undetected Chromedriver Mode / CDP Mode
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant