Closed officicalalkhaldi closed 6 days ago
The uc_gui_click_captcha()
method automatically checks to see if there's a CAPTCHA before trying to click one.
If there's no CAPTCHA on the page, then nothing happens when that method is called.
Ok, sounds good.
Thanks in advance !
Hi, I’m using SeleniumBase on Windows, and I’m having trouble figuring out how to handle websites that sometimes throw a CAPTCHA challenge (like Cloudflare Turnstile).
Here’s what I’m trying to do:
I’ve written a script to open a website and click the CAPTCHA using uc_gui_click_captcha() method. But the problem is that I don’t know how to detect if the CAPTCHA is actually present before calling that method. Sometimes the challenge doesn’t show up, and I don’t want the script to break or waste time trying to click a CAPTCHA that’s not there.
Here’s the script I’m using:
f there’s a better way to handle this scenario, maybe an if statement It’d valuable to me and maybe to others, I really appreciate any guidance.
Thanks in advance!