1

I'm using chrome webdriver with selenium and python.

I get this console messages on command terminal.

console

Also, the html file is located on my machine: file:///D:/serp/5e577f17e0d7ae57db776c0b/dumps/1.html

Here's the chrome options:

chrome_options = Options()
chrome_options.add_argument("--headless")
chrome_options.add_argument('--lang=en-GB')
chrome_options.add_argument('--disable-web-security')
chrome_options.add_argument('--disable-gpu')
chrome_driver = os.getcwd() + "\\chromedriver.exe"
driver = webdriver.Chrome(chrome_options=chrome_options, executable_path=chrome_driver)
driver.get(url_string)

How do I disable those messages?

Azima
  • 3,835
  • 15
  • 49
  • 95

1 Answers1

4

Try this Once :

from selenium.webdriver.chrome.options import Options

chrome_options = Options()
chrome_options.add_argument('--headless')
chrome_options.add_experimental_option('excludeSwitches', ['enable-logging'])
chrome_options.add_argument('--log-level=3')
driver = webdriver.Chrome(options=chrome_options)
Amar Kumar
  • 2,392
  • 2
  • 25
  • 33