You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

使用Undetected ChromeDriver结合Selenium登录Snapchat仍触发验证码问题求助

Undetected ChromeDriver结合Selenium登录Snapchat仍触发验证码问题求助

各位大佬好,我最近碰到个棘手的问题:每次尝试登录Snapchat都会触发验证码,完全没法跳过。之前了解到undetected-chromedriver可以规避网站的反爬检测,就试着用它来替代普通的ChromeDriver,但试了之后验证码还是照样弹出来,实在没辙了。

下面是我目前写的代码片段:

import undetected_chromedriver as uc
self.driver = uc.Chrome()

def login(self):
        print('GET LOGIN')
        self.driver.get("https://accounts.snapchat.com/accounts/v2/login")

        print(self.user_creds['username'])
        try:
            accept_all_button = self.driver.find_element(By.XPATH, "//button[span[contains(text(), 'Accept All')]]")
            accept_all_button.click()
            print("Clicked 'Accept All' button to remove overlapping elements.")
            # 后续的用户名密码输入逻辑还没完成,但到这一步已经触发验证码了
        except Exception as e:
            print(f"Error clicking accept button: {e}")

想请教下各位,是不是我对undetected-chromedriver的使用方式有问题?或者还有什么额外的配置、技巧能绕过Snapchat的验证码检测?麻烦大家给点思路,非常感谢!

备注:内容来源于stack exchange,提问作者beni14

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.04.16 08:28:06