本地和Dockerized我使用相同的版本
Python 2.7 + Selenium(我认为最新的哪个地方可以看到它?)+ Firefox(最新59.01)
仅限FIREFOX当地:
打印每秒正确返回正确的值
//click button on webpage
elementbutton = driver.find_element_by_class_name("buttonclassname")
elementbutton.click()
(some code Blabla...)
//Read in a loop value from web element
progressvalue = driver.find_element_by_class_name("progress").text
print ("progress", progressvalue)
工作FIREFOX和CHROME LOCAL:
打印每秒正确返回正确的值
//click button on webpage
elementbutton = driver.find_element_by_class_name("buttonclassname")
//this click does work in firefox and in chrome but uses Javascript click
driver.execute_script("arguments[0].click();", elementbutton)
(some code Blabla...)
//Read in a loop value from web element
progressvalue = driver.find_element_by_class_name("progress").text
print ("progress", progressvalue)
__
不在FIREFOX&不是在适当的时候
//click button on webpage
elementbutton = driver.find_element_by_class_name("buttonclassname")
elementbutton.click()
(some code Blabla...)
//Read in a loop value from web element
progressvalue = driver.find_element_by_class_name("progress").text
print ("progress", progressvalue)
仅限工作时间
//click button on webpage
elementbutton = driver.find_element_by_class_name("buttonclassname")
driver.execute_script("arguments[0].click();", elementbutton)
(some code Blabla...)
//Read in a loop value from web element
progressvalue = driver.find_element_by_class_name("progress").text
print ("progress", progressvalue)
打印仅在chrome中返回正确的值,在Firefox中它始终返回0,该元素在Firefox中不刷新
似乎javascript可能无法正常工作或未启用? 为什么?这是一个壁虎驱动程序错误?