2

I am a beginner with Selenium. I can not seem to disable the "AutomationControlled" flag in Chrome. according to this article: https://piprogramming.org/articles/How-to-make-Selenium-undetectable-and-stealth--7-Ways-to-hide-your-Bot-Automation-from-Detection-0000000017.html#:~:text=%207%20Ways%20to%20hide%20your%20Bot%20Automation,you%20if%20you%20are%20using%20Linux...%20More%20, there are 2 main ways of doing this. One of them can be done before instantiating the driver so that not even Chrome knows that is is being controlled by Selenium. This is the one I am interested in, but I can not get it to work. Here is what I have:

    from selenium import webdriver

    option = webdriver.ChromeOptions()
    option.add_argument('--disable-blink-features=AutomationControlled')
    browser = webdriver.Chrome(executable_path='chromedriver.exe',options=option)

I dont get any errors with this but Chrome sure knows it is being controlled by Selenium bc the banner shows along the top of the browser. I have tried to confirm if the flag AutomationControlled is set but I cannot find where I can check this. I am running Chromedriver 87. something.

Any help is appreciated.

Matheus Delazeri
  • 425
  • 2
  • 15

0 Answers0