element not interactable,这种提示表示元素当前在页面上不可见

一种可能是元素当前不可访问,因为它不可见。原因可能是另一个元素正在覆盖它或它不在视图中,即它在当前可查看区域之外。

试试这个

from selenium.webdriver.common.action_chains import ActionChains

button = driver.find_element_by_class_name(u"infoDismiss")
driver.implicitly_wait(10)
ActionChains(driver).move_to_element(button).click(button).perform()
posted @ 2021-12-19 15:40  星钥无痕  阅读(263)  评论(0编辑  收藏  举报