gpt4 book ai didi

ruby - Watir 消息 : Instead of passing arguments into #wait_until_present method, 使用关键字

转载 作者:数据小太阳 更新时间:2023-10-29 07:25:30 30 4
gpt4 key购买 nike

我在填写表格后使用 watir 和 firefox 抓取网页。这是我的代码的一小部分:

browser.button(:type => 'submit').click
sleep 10
browser.element(:id => 'footer').wait_until_present(timeout=30)
html = browser.html

出现此消息:

Instead of passing arguments into #wait_until_present method, use Keywords

这是什么意思?我该如何解决这个问题?感谢您的帮助。

最佳答案

答案在新的 Watir 6.0 常见问题解答中: http://watir.github.io/watir-6-faq/#G

在您的情况下,将 timeout=30 更改为 timeout: 30,您将不会看到警告消息。

关于ruby - Watir 消息 : Instead of passing arguments into #wait_until_present method, 使用关键字,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/40702113/

30 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com