Таким образом, на веб-странице есть кнопка, которая после нажатия добавит элемент на веб-страницу, в котором я не могу найти, используя selenium
Некоторый воображаемый код, описанный ниже, чтобы объяснить возникшую проблему:
from selenium import webdriver
d = webdriver.Chrome()
#Go to my target website
d.get("https://some_website_url") #ref1
#Okay now loading of the website is done. `d` will not be updated and this is the problem!!
#Click my target button and an element with id="SecretButton" is loaded.
d.find_element_by_css_selector("#secretlyupdatethewebpage").click()
#Find #SecretButton but to no avail.
#It can be found in the html panel of Chrome Developer Tools
#but cannot be found in the webdriver `d`, as `d` won't be
#updated after #ref1
d.find_element_by_css_selector("#SecretButton").click()
Как мне найти #SecretButton?