How to disable logging using Selenium with Python binding

后端 未结 4 1799
误落风尘
误落风尘 2020-12-04 01:45

Simple question: how to completely disable logging when using Selenium from Python bindings, ex code as follows:

browser = webdriver.Chrome()
4条回答
  •  旧时难觅i
    2020-12-04 02:26

    Just example for Windows people:

    webdriver.Firefox(log_path='NUL')
    

    Accepted answer is correct, but if you are new to Python / windows like i am, example like this will cut you few hours of google time.

提交回复
热议问题