Menu

Toshimaru's Blog

How to fix "This version of ChromeDriver only supports Chrome version xx" on Ubuntu

Issue

When I was running CI on GitHub Actions, CI on Ubuntu suddenly gets an error.

The error says:

Failures:

  1) ...
     Got 0 failures and 2 other errors:

     1.1) Failure/Error: visit login_path

          Selenium::WebDriver::Error::SessionNotCreatedError:
            session not created: This version of ChromeDriver only supports Chrome version 79

     1.2) Failure/Error: Unable to infer file and line number from backtrace

          Selenium::WebDriver::Error::SessionNotCreatedError:
            session not created: This version of ChromeDriver only supports Chrome version 79

The error message is:

Selenium::WebDriver::Error::SessionNotCreatedError:
  session not created: This version of ChromeDriver only supports Chrome version 79

Solution 1

The error message basically says “your Chrome version is outdated”, so install the latest chrome with chromedriver (chromium-driver).

- sudo apt-get install libsqlite3-dev chromium-driver
+ sudo apt-get install libsqlite3-dev chromium-driver google-chrome-stable

Solution 2

Another solution is removing outdated Google Chrome (google-chrome-stable) on the machine. By doing so, CI uses chromium as a browser instead of google-chrome.

+ sudo apt-get remove google-chrome-stable
  sudo apt-get install libsqlite3-dev chromium-driver

See also

Load more