seleniumbase / SeleniumBase

📊 Python's all-in-one framework for web crawling, scraping, testing, and reporting. Supports pytest. UC Mode provides stealth. Includes many tools.
https://seleniumbase.io
MIT License
4.46k stars 909 forks source link

UC Mode no longer working for Cloudflar turnstiles? #2801

Closed davidjivan closed 1 month ago

davidjivan commented 1 month ago

is this code still supposed to be working?

from seleniumbase import SB

with SB(uc=True, test=True) as sb:
    url = "https://gitlab.com/users/sign_in"
    sb.driver.uc_open_with_reconnect(url, 3)
    if not sb.is_text_visible("Username", '[for="user_login"]'):
        sb.driver.uc_open_with_reconnect(url, 4)
    sb.assert_text("Username", '[for="user_login"]', timeout=3)
    sb.assert_element('label[for="user_login"]')
    sb.highlight('button:contains("Sign in")')
    sb.highlight('h1:contains("GitLab.com")')
    sb.post_message("SeleniumBase wasn't detected", duration=4)
mdmintz commented 1 month ago

SeleniumBase/examples/raw_uc_mode.py is still working for me.

davidjivan commented 1 month ago

Any advice on troubleshooting why it's not working for me?

davidjivan commented 1 month ago

Nevermind! It took reconnect_time=30 but got there. BTW big thanks for this project and love the long form YT videos.