Session not created exception: Chrome version must be >= x.y.z when using Selenium Webdriver with Chrome

ChrisWilson picture ChrisWilson · Mar 16, 2018 · Viewed 12k times · Source

A few notes that make this tricky are that I'm using c9.io (developing in the cloud) so I use the gem webdrivers to be able to run Chrome with Watir, instead of creating an executable path to the Chrome installed on my device.

My code was working until I logged in today and got the error

session not created exception: Chrome version must be >= 64.0.3282.0 (Driver info: chromedriver=2.37.543610 (afd36256570660b5a2f0e4dbd1b040f3dcfe9cb5),platform=Linux 4.9.80-c9 x86_64)

Relevant parts of gemfile (everything else is stock)

gem 'webdrivers'

gem 'watir'

Code I'm trying to compile

def mastersave
    require 'watir'
    @browser = Watir::Browser.new :chrome, headless: true
end

I'm not stuck on the idea of using Chrome, but it's what was working for me. The gem 'webdrivers' also allows me to use firefox, but I get the error 'permission denied' with that.

Answer

natsbat4ws picture natsbat4ws · Apr 26, 2019

For those that have just had this problem going from Chrome 73 to 74 it might be because you are using chromedriver-helper. Apparently the chromedriver-helper gem was deprecated. I switched to using the webdrivers gem and it fixed the issue.

In Gemfile replace: gem 'chromedriver-helper'

With: gem 'webdrivers', '~> 3.0'

bundle install