Google chrome 29.0 is not working with webdriver - google-chrome

I was trying to load google chrome browser with watir-webdriver, but while invoking any URL in the browser it is throwing following error
Selenium::WebDriver::Error::UnknownError: Unknown command 'WaitForAllTabsToStopL
oading'. Options: AcceptOrDismissAppModalDialog, ActionOnSSLBlockingPage, Activa
teTab, AddBookmark, AddDomEventObserver, AppendTab, ApplyAccelerator, BringBrows
erToFront, ClearEventQueue, CloseBrowserWindow, CloseTab, CreateNewAutomationPro
vider, DeleteCookie, DeleteCookieInBrowserContext, DoesAutomationObjectExist, Dr
agAndDropFilePaths, ExecuteJavascript, ExecuteJavascriptInRenderView, GetActiveT
abIndex, GetAppModalDialogMessage, GetBookmarkBarStatus, GetBookmarksAsJSON, Get
BrowserInfo, GetBrowserWindowCount, GetChromeDriverAutomationVersion, GetCookies
, GetCookiesInBrowserContext, GetDownloadDirectory, GetExtensionsInfo, GetIndice
sFromTab, GetLocalStatePrefsInfo, GetMultiProfileInfo, GetNextEvent, GetPrefsInf
o, GetProcessInfo, GetSecurityState, GetTabCount, GetTabIds, GetTabInfo, GetView
s, GoBack, GoForward, InstallExtension, IsDownloadShelfVisible, IsFindInPageVisi
ble, IsMenuCommandEnabled, IsPageActionVisible, IsTabIdValid, MaximizeView, Navi
gateToURL, OpenFindInPage, OpenNewBrowserWindow, OpenNewBrowserWindowWithNewProf
ile, OpenProfileWindow, OverrideGeoposition, RefreshPolicies, Reload, RemoveBook
mark, RemoveEventObserver, ReparentBookmark, RunCommand, SendWebkitKeyEvent, Set
BookmarkTitle, SetBookmarkURL, SetCookie, SetCookieInBrowserContext, SetDownload
ShelfVisible, SetExtensionStateById, SetLocalStatePrefs, SetPrefs, SetViewBounds
, SimulateAsanMemoryBug, TriggerBrowserActionById, TriggerPageActionById, Uninst
allExtensionById, UpdateExtensionsNow, WaitForBookmarkModelToLoad, WaitUntilNavi
gationCompletes, WebkitMouseButtonDown, WebkitMouseButtonUp, WebkitMouseClick, W
ebkitMouseDoubleClick, WebkitMouseDrag, WebkitMouseMove, AcceptCurrentFullscreen
OrMouseLockRequest, AddOrEditSearchEngine, AddSavedPassword, CloseNotification,
DenyCurrentFullscreenOrMouseLockRequest, DisablePlugin, EnablePlugin, FindInPage
, GetAllNotifications, GetDownloadsInfo, GetFPS, GetHistoryInfo, GetInitialLoadT
imes, GetNTPInfo, GetNavigationInfo, GetOmniboxInfo, GetPluginsInfo, GetSavedPas
swords, GetSearchEngineInfo, GetV8HeapStats, ImportSettings, IsFullscreenBubbleD
isplayed, IsFullscreenBubbleDisplayingButtons, IsFullscreenForBrowser, IsFullscr
eenForTab, IsFullscreenPermissionRequested, IsMouseLockPermissionRequested, IsMo
useLocked, KillRendererProcess, LaunchApp, LoadSearchEngineInfo, OmniboxAcceptIn
put, OmniboxMovePopupSelection, PerformActionOnDownload, PerformActionOnInfobar,
PerformActionOnSearchEngine, RemoveNTPMostVisitedThumbnail, RemoveSavedPassword
, RestoreAllNTPMostVisitedThumbnails, SaveTabContents, SetAppLaunchType, SetOmni
boxText, SetWindowDimensions, WaitForAllDownloadsToComplete, WaitForNotification
Count,
It might be throwing this error because of Chrome update where as webdriver is not supporting the updated API's,
I also tried to update watir-webdriver gem, but it is saying nothing to update (its up to date) My watir-webdriver version is watir-webdriver-0.6.4
Kindly let me know if any one else is facing the same issue or any one found out the solution for the same.

Gaurav, I've had the same issue.
Here are the steps how i fixed this:
1. Remove old the versions (ruby, watir, devkit)
2. Install to Ruby 2.0.0-p195
3. Install devkit
4. Add latest chromedriver to your $PATH
5. gem install watir-webdriver
6. gem update --system
7. gem update
8. gem cleanup
Also update the chromedriver executable to the latest version (and double check it in your path).
I have: ruby 2.0.0p195 (2013-05-14) [i386-mingw32] && watir-webdriver(0.6.4)
Voila:
C:\Ruby200\bin>irb
irb(main):001:0> require "watir-webdriver"
=> true
irb(main):002:0> b = Watir::Browser.new :chrome
Starting ChromeDriver (v2.2) on port 9515
=> #<Watir::Browser:0x3cac37de url="data:text/html;charset=utf-8," title="data:t
ext/html;charset=utf-8,">
irb(main):003:0> b.goto "stackoverflow.com"
=> "http://stackoverflow.com/"
irb(main):004:0> b.inspect
=> "#<Watir::Browser:0x50eee9c0 url=\"http://stackoverflow.com/\" title=\"Stack
Overflow\">"
Please let me know if it helped.

I am also facing the same issue. I am getting this error exactly when I am trying to navigate to driver.goto("google.com").
But if I revert my Chrome version from 29 to 27 then its working fine. So I think the issue is from chrome version 29 or chrome driver version chromedriver_win32_2.2.zip
So please downgrade the chrome temporarily....

Download the latest version of chromedriver. Also make sure that the old old on NOT in your PATH.

Did you upgrade to the latest version of selenium-webdriver?
gem install selenium-webdriver
Remember that watir-webdriver is just a wrapper around selenium-webdriver. It is actually selenium-webdriver that does the interaction with chromedriver. Typically, when there is an update to chromedriver, there also needs to be an update to selenium-webdriver.
There were 2 updates to selenium-webdriver since the latest chromedriver update. It is possible that one of the updates addressed your issue.

Use the Latest jar file of selenium web driver- selenium-server-standalone-2.35.0.jar
and chromedriver_win32_2.3.zip for chrome driver.

I have seen this issue and we fixed it by moving to ChromeDriver 2.3 in both Mac and Windows
Versions I use:
Ruby version: 1.9.3-p194
Watir-webdriver version: 0.6.4
Selenium-webdriver version: 2.33.0
if you can make sure chrome driver is in the PATH, this should work. No need to upgrade to ruby 2.0.

You would use capabilities to point to the right binary file of the browser to be launced.But not all versions of chrome browser is supported by different versions of chromedriver. You will find exceptions stating that version of browser expected is greater or equal to 30.0.
For ex:- Chromium Browser(33.0.1729.0 )works fine with ChromeDriver 2.7 and not the with the older ones.
You can choose from all the chromedriver version available from the link below:- http://chromedriver.storage.googleapis.com/index.html
So try to use the browser version supported by the chromedriver.

Related

Find Chrome Driver Version Used

We have below webdrivermanager version in our pom. But is there anyway you can see/find the version of chromedriver used by it?:-
<webdrivermanager.version>3.8.0</webdrivermanager.version>
Ok, I have found it from trace while running the tests:-
Starting ChromeDriver 80.0.3987.106 (f68069574609230cf9b635cd784cfb1bf81bb53a-refs/branch-heads/3987#{#882}) on port 36187
Only local connections are allowed.

WebdriverIO - Test fails with error Openfin

I have been trying to setup automation testing for our openfin application using the below repo as base
https://github.com/openfin/webinar-automated-integration-tests
I am using Openfin (Chrome version 61.0.3163.100) and Chromedriver 2.40.565498
When I run "npm test", the openfin application opens up. But the tests don't run. After waiting for sometime, it throws the below error in console.
ERROR: unknown error: DevToolsActivePort file doesn't exist
(Driver info: chromedriver=2.40.565498 (ea082db3280dd6843ebfb08a625e3eb905c4f5ab),platform=Windows NT 10.0.16299 x86_64)
chrome
I tried using other versions of chromedriver like 2.33, 2.34, 2.37, 2.38, 2.39, 2.41. Using these versions even the application doesn't appear. So, I guess the chromedriver version I am using is correct. I have also tried adding the below arguments to chromeOptions
--remote-debugging-port=9222,--no-sandbox,--headless,--disable-gpu
They didn't solve my issue. Not sure what is causing the issue. Any help would be much appreciated. Thanks in advance. Cheers!
This error message...
ERROR: unknown error: DevToolsActivePort file doesn't exist
(Driver info: chromedriver=2.40.565498 (ea082db3280dd6843ebfb08a625e3eb905c4f5ab),platform=Windows NT 10.0.16299 x86_64)
...implies that the ChromeDriver was unable to initiate/spawn a new Browsing Context i.e. Chrome Browser session.
Your main issue is the incompatibility between the version of the binaries you are using as follows:
You are using chromedriver=2.40
Release Notes of chromedriver=2.40 clearly mentions the following :
Supports Chrome v66-68
Presumably you are using chrome=61.0
Release Notes of ChromeDriver v2.33 clearly mentions the following :
Supports Chrome 60-62
Your Selenium Client version is unknown to us.
So there is a clear mismatch between ChromeDriver v2.40 and the Chrome Browser v60.0
Solution
Ensure that:
Selenium is upgraded to current levels Version 3.141.59.
ChromeDriver is updated to current ChromeDriver v80.0 level.
Chrome is updated to current Chrome Version 80.0 level. (as per ChromeDriver v80.0 release notes)
Clean your Project Workspace through your IDE and Rebuild your project with required dependencies only.
If your base Web Client version is too old, then uninstall it and install a recent GA and released version of Web Client.
Take a System Reboot.
Execute your #Test as non-root user.
Always invoke driver.quit() within tearDown(){} method to close & destroy the WebDriver and Web Client instances gracefully.

OpenFin Chrome version must be >= 66.0.3359.181

So I was using ChromeDriver 2.40 which worked great with OpenFin 10.66.41.18 or Chromium 66.0.3359.181 if you prefer.
However after upgrading to latest OpenFin stable version (11.69.42.29), I started getting an error denoting version mismatch between ChromeDriver and Chromium:
Chrome version must be >= 66.0.3359.181
Fair enough, I thought and downloaded Chromedriver 2.44 which is the closest I can get to v69, still getting an error:
Chrome version must be >= 69.0.3497.0
So, close but no cigar as OpenFin now runs on Chromium 69.0.3497.128
But that means we reached a dead end completely losing the ability to automate OpenFin as if you get the next available ChromeDriver (so 2.45) you get an error that chrome:
Chrome version must be between 70 and 73
In other words, latest stable version of OpenFin is not supported with a matching ChromeDriver. Just raising this in case anyone else is experiencing the same issue.
As a workaround I reverted back to 10.66.41.18 as I'm using a config file to launch my app.
So, I've changed from:
"runtime": {
"version": "stable"
}
to this one:
"runtime": {
"version": "10.66.41.18"
}

Exception: unknown error: Chrome version must be >= 53.0.278 5.0

I am trying to setup e2e test using protractor, keep on getting Chrome version must be >= 53.0.278 5.0 error.
Environment:
OS: Windows 7(64 bit)
Chrome: 44(I am not allowed to upgrade to latest version)
Protractor: 5.0.0
ChromeDriver: 2.26
SeleniumStandalone: 2.53.1
Thanks.
ChromeDriver 2.26 supports Chrome v53-55 as described here.
Downgrade your ChromeDriver with the command webdriver-manager update --versions.chrome 2.20. This would install ChromeDriver 2.20 which is compatible with Chrome v43-48.

cannot run Selenium tests on some browsers

i have tests made with Mink using Selenium 2 driver. everything is working OK under Windows 7 with Firefox, Chrome and IE and Ubuntu 12.10 with Firefox. the problems are:
when i try to run test on Opera (Windows 7) it launches but it cannot find any element on the page - the test fails.
when i try to run test on Chrome (Ubuntu 12.10) using chromedriver - the system returns an error "An unknows server side error occured while processing the command".
when i try to run test on Opera (Ubuntu 12.10) - the system returns an error "No response in timely fashion".
what am i doing wrong? how can i make work Opera in Windows and Opera and Chrome in Ubuntu?
p.s. i use system as Selenium Grid 2
For me on Windows it work:
java -jar "c:\selenium-server-standalone-2.35.0.jar" -forcedBrowserMode "*googlechrome c:\Program Files\Google\Chrome\Application\chrome.exe"
May be for u:
java -jar "c:\selenium-server-standalone-2.35.0.jar" -forcedBrowserMode "*opera c:\Program Files\pathToOpera.exe"
It might be a matter of Operative System as well.
I am developing on a Windows machine and my colleagues are working on Mac.
They had just included the chrome driver for mac, so tests didntĀ“t work on my computer.
I had to do this:
if (OS.indexOf("win") >= 0) {
System.setProperty("webdriver.chrome.driver", "src/test/resources/selenium_drivers/chromedriver.exe");
} else if ((OS.indexOf("mac") >= 0)) {
System.setProperty("webdriver.chrome.driver", "src/test/resources/selenium_drivers/chromedriver");
}
Two different driversa that you can find at http://chromedriver.storage.googleapis.com/index.html