Im working on small project and im logging there in to quizlet. The problem is that when I run my program without any chrome driver options there is no problem it works perfectly fine. But where I add my arguments the quizlet won't let me login.
Those are my arguments:
CHROME_PATH = r'C:\Program Files (x86)\Google\Chrome\Application\chrome.exe'
CHROMEDRIVER_PATH = r"C:\Program Files (x86)\Python38-32\chromedriver.exe"
WINDOW_SIZE = "3840,2160"
chrome_options = Options()
chrome_options.add_argument("--headless")
chrome_options.add_argument("--incognito")
chrome_options.add_argument("--window-size=%s" % WINDOW_SIZE)
chrome_options.binary_location = CHROME_PATH
driver = webdriver.Chrome(executable_path=CHROMEDRIVER_PATH, options=chrome_options)
as you can see i get an error:
here is a picture of error
when i edit this line:
driver = webdriver.Chrome(executable_path=CHROMEDRIVER_PATH)
it works perfectly but i don't want to see the window.
I looks like '--headless' argument triggers safety features of the webside.
This is so weird. Any sugestions?