i use selenium chromedriver for make a program that automaticly go to nike.com and accept the cookie, but, for accept the cookie, the chromedriver must to find the cookie button with :
button = browser.find_element(By.CLASS_NAME,
"div[class='ncss-row']div[class='ncss-col-sm-12 ncss-col-md-6'] button[class='ncss-btn-primary-dark pt3-sm pb3-sm pt2-lg pb2-lg ta-sm-c u-full-width']"
)
but, when i start my program :
import webbrowser
import undetected_chromedriver as uc
from selenium import webdriver
from time import sleep
from selenium.webdriver.common.by import By
def main():
browser = uc.Chrome()
browser.get('https://www.nike.com/fr/snkrs-app?cp=24158993452_search_%7Csnkrs%7C10689554523%7C109060467241%7Ce%7Cc%7CFR%7Capp%7C508994633917&gclsrc=aw.ds&ds_rl=1252249&gclid=CjwKCAjwk_WVBhBZEiwAUHQCmV8yy66lssIN5EzoS0K8I4B1k9yk5kduxXy62w27SLfnChI_0U4UvBoC4P8QAvD_BwE')
sleep(8)
button = browser.find_element(By.CLASS_NAME, "div[class='ncss-row']
div[class='ncss-col-sm-12 ncss-col-md-6'] button[class='ncss-btn-primary-dark pt3-sm pb3-sm pt2-lg pb2-lg ta-sm-c u-full-width']")
button.click()
sleep(100000)
if __name__ == '__main__':
main()
So, when i start the program, he say that he not found the button, and i have tried a lot of solution, but i don't find the good program to do that.
This is a picture of the code of the boutton.