I have been trying to use python-selenium to automate the login to google, but after I enter the username and click on next I get the message
Couldn’t sign you in
That is probably because the webpage detects that the chrome browser is controlled by test automation software. But I already tried to exclude that switch using the following setup code:
options = webdriver.ChromeOptions()
options.add_experimental_option("excludeSwitches", ["enable-automation"])
driver = webdriver.Chrome(options=options)
but it still does not work. I am using chrome 98.
How can I fix that problem? Or maybe there is another way to automatically log in to a google account using python-selenium and a username/password combination?