My Chrome browser is updated to version 78 and when I tried to execute any code of automation, it shows the error
Please protect ports used by ChromeDriver and related test frameworks to prevent access by malicious code.
[1573451703.668][WARNING]: Timed out connecting to Chrome, retrying...
Nov 11, 2019 11:25:05 AM org.openqa.selenium.remote.ProtocolHandshake createSession
INFO: Detected dialect: W3C
[1573451709.039][WARNING]: Timed out connecting to Chrome, retrying...
How can I fix it?
This error message...
Please protect ports used by ChromeDriver and related test frameworks to prevent access by malicious code.
[1573451703.668][WARNING]: Timed out connecting to Chrome, retrying...
Nov 11, 2019 11:25:05 AM org.openqa.selenium.remote.ProtocolHandshake createSession
INFO: Detected dialect: W3C
[1573451709.039][WARNING]: Timed out connecting to Chrome, retrying...
...implies that the ChromeDriver was unable to initiate/spawn a new WebBrowser i.e. Chrome Browser session.
The first log message:
Please protect ports used by ChromeDriver and related test frameworks to prevent access by malicious code.
is part of the startup log when using ChromeDriver and is informative in nature.
You can find a detailed discussion in How do I protect the ports that chromedriver use?
The following log message:
[1573451703.668][WARNING]: Timed out connecting to Chrome, retrying...
indicates there are some incompatibility between the version of the binaries you are using.
Ensure that:
@Test
as non-root user.driver.quit()
within tearDown(){}
method to close & destroy the WebDriver and Web Client instances gracefully.