How to start Chromedriver in verbose mode - Selenium Eclipse

你。 提交于 2019-12-04 08:44:04

Here's a script that creates the executable you'll need, cd to the directory where chromedriver is, then paste this into your console:

cat <<EOF>chromedriververbose
echo "running chromedriver --verbose \$*"
\$(dirname \$0)/chromedriver --verbose \$*
EOF

chmod +x chromedriververbose

That'll create an executable script called chromedriververbose that you can point your tests at rather than chromedriver.

Alternatively, you could rename chromedriver to chromedriversilent and then call the above script chromedriver and point it to chromedriversilent for drop-in replacement.

To fix this issue, you can download the latest Chromedriver version 2.6 which resolves this issue.

Link - http://chromedriver.storage.googleapis.com/index.html

I did the following from within the python console to test the verbose thing:

driver = webdriver.Chrome(service_args=["--verbose"])

It seemed to do the trick. Not ideal but it works for now.

You can set command line flags in the capabilities (Java example)

capability = DesiredCapabilities.chrome();
capability.setCapability("chrome.switches",
    Arrays.asList("--verbose"));
webDriver = new RemoteWebDriver(new URL(url), capability);

However I'm not seeing this actually solve the problem on my end, I still get

org.openqa.selenium.WebDriverException: unknown error: Chrome failed to start: was killed

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!