Feature and motivation
Geckodriver has this great feature allowing users to specify the output stream of the service process.
https://github.com/SeleniumHQ/selenium/blob/selenium-4.8.0/java/src/org/openqa/selenium/firefox/GeckoDriverService.java#L203-L225
It should be pretty trivial to support this in the other Driver Service classes as well.
For Chrome/Edge we are currently using the driver itself to send logged information to a file:
args.add(String.format("--log-path=%s", getLogFile().getAbsolutePath()));
I think porting all of the process output is a better option, though we probably need some tests to verify there isn't some other oddness as a result.
One big difference is that if we are sending the whole stream to another place, the user won't have to see this in their console:
Starting ChromeDriver 109.0.5414.74 (e7c5703604daa9cc128ccf5a5d3e993513758913-refs/branch-heads/5414@{#1172}) on port 26243
Only local connections are allowed.
Please see https://chromedriver.chromium.org/security-considerations for suggestions on keeping ChromeDriver safe.
ChromeDriver was started successfully.
Usage example
System.setProperty("webdriver.chrome.logfile", "/dev/null")
Feature and motivation
Geckodriver has this great feature allowing users to specify the output stream of the service process.
https://github.com/SeleniumHQ/selenium/blob/selenium-4.8.0/java/src/org/openqa/selenium/firefox/GeckoDriverService.java#L203-L225
It should be pretty trivial to support this in the other Driver Service classes as well.
For Chrome/Edge we are currently using the driver itself to send logged information to a file:
I think porting all of the process output is a better option, though we probably need some tests to verify there isn't some other oddness as a result.
One big difference is that if we are sending the whole stream to another place, the user won't have to see this in their console:
Usage example