defecationwarning:find_element_by_*命令已弃用
我正在尝试恢复我的旧脚本,该脚本一直奏效。自从我切换到Python 3以来,我遇到了很多问题。启动脚本后出现了此错误:
DeprecationWarning: find_element_by_* commands are deprecated
这是提出问题的代码行:
driver.find_element_by_xpath("//*[@title='Consent all cookies']").click()
有人可以帮助我吗?
I'm trying to recover an old script of mine, which has always worked. Since I switched to Python 3 though, I'm having a lot of problems. This error came up after launching the script:
DeprecationWarning: find_element_by_* commands are deprecated
This is the line of the code which presents the problem:
driver.find_element_by_xpath("//*[@title='Consent all cookies']").click()
Can anyone help me?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您需要添加以下导入:
然后替换以下:
以下:
You need to add the following import:
Then replace this:
with this: