我使用selenium作为web抓取器,希望定位多个表,然后为每个表(通过循环)定位该表中的一个元素(无需再次遍历整个文档)。我正在使用Iwebelement.FindElements(By.XPath),但一直出现错误,提示'element no longer connected to DOM‘IList[IWebElement] elementsB = driver.FindElements(By.XPath("
, '//div[@class="ant-card ant-card-bordered" and //*[contains(text(), "Access Points")]]'))) 其中该特定的xpath元素在页面上不存在。Image of page where xpath element does not exist 因此,我预计测试用例会失败。奇怪的是,它确实使用docker镜像按照预期工作,并成功