且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

如何使用 Selenium 和 Python 绑定禁用日志记录

更新时间:2022-06-04 01:03:07

源代码,显示了一个名为 service_log_path 的选项的存在.

The source code of Chrome's webdriver, shows the existence of an option called service_log_path.

所以如果你想摆脱文件,你可以设置这个属性为

So if you want to get rid of the file, you could set this property to

  • /dev/null 如果你在 Linux/Unix 下运行;
  • NULwindows下
  • /dev/null if you are running under Linux/Unix ;
  • NUL under windows

希望对你有帮助