https://github.com/titusfortner/webdrivers
Keep your Selenium WebDrivers updated automatically
https://github.com/titusfortner/webdrivers
Keywords
hacktoberfest selenium webdriver
Keywords from Contributors
activerecord activejob mvc rspec rubygems rubocop rack multithreading static-analysis sinatra
Last synced: about 3 hours ago
JSON representation
Repository metadata
Keep your Selenium WebDrivers updated automatically
- Host: GitHub
- URL: https://github.com/titusfortner/webdrivers
- Owner: titusfortner
- License: mit
- Created: 2017-08-15T22:39:53.000Z (over 8 years ago)
- Default Branch: main
- Last Pushed: 2024-01-24T16:51:32.000Z (almost 2 years ago)
- Last Synced: 2025-12-31T13:39:52.083Z (10 days ago)
- Topics: hacktoberfest, selenium, webdriver
- Language: Ruby
- Homepage:
- Size: 413 KB
- Stars: 600
- Watchers: 11
- Forks: 109
- Open Issues: 1
- Releases: 20
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE.txt
README.md
Webdrivers
Run Selenium tests more easily with automatic installation and updates for all supported webdrivers.
Update: Future of this Project
With Google's new Chrome for Testing project,
and Selenium's new Selenium Manager feature,
what is required of this gem has changed.
If you can update to the latest version of Selenium (4.11+), please do so and stop requiring this gem.
Provide feedback or raise issues to Selenium Project
If you cannot upgrade to Selenium 4.11, Webdrivers 5.3.0 will continue to support Ruby 2.6+ and Selenium 4.0 - 4.10
Webdrivers 6.0
To provide support for Selenium 3 and Ruby < 2.6 a 6.0 version is planned. It requires:
- Creating a
selenium-manager.gembased off of https://github.com/SeleniumHQ/selenium/pull/12429 - Re-implementing this gem to wrap
selenium-manager.gem - Ensuring compatible with older versions of Selenium & Ruby
If anyone would like to help get Webdrivers 6 working, please let us know.
Description
webdrivers downloads drivers and directs Selenium to use them. Currently supports:
Works on macOS, Linux, Windows, and Windows Subsystem for Linux (WSL) v1 and v2. And do see the browser and OS specific
notes at the bottom.
Usage
In your Gemfile:
gem 'webdrivers', '~> 5.0', require: false
In your project:
require 'webdrivers'
The drivers will now be automatically downloaded or updated when you launch a browser
through Selenium.
Specific Drivers
If you want webdrivers to only manage specific drivers you can specify one or more as follows:
require 'webdrivers/chromedriver'
require 'webdrivers/geckodriver'
require 'webdrivers/iedriver'
require 'webdrivers/edgedriver'
Download Location
The default download location is ~/.webdrivers directory, and this is configurable:
Webdrivers.install_dir = '/webdrivers/install/dir'
Alternatively, you can define the path via the WD_INSTALL_DIR environment
variable.
Version Pinning
If you would like to use a specific (older or beta) version, you can specify it for each driver. Otherwise,
the latest (stable) driver will be downloaded and passed to Selenium.
# Chrome
Webdrivers::Chromedriver.required_version = '2.46'
# Firefox
Webdrivers::Geckodriver.required_version = '0.23.0'
# Internet Explorer
Webdrivers::IEdriver.required_version = '3.14.0'
# Edge (Chromium)
Webdrivers::Edgedriver.required_version = '76.0.183.0'
You can explicitly trigger the update in your code, but this will happen
automatically when the driver is initialized:
Webdrivers::Chromedriver.update
Caching Drivers
You can set Webdrivers to only look for updates if the previous check
was longer ago than a specified number of seconds.
Webdrivers.cache_time = 86_400 # Default: 86,400 Seconds (24 hours)
Alternatively, you can define this value via the WD_CACHE_TIME environment
variable. Only set one to avoid confusion.
Special exception for chromedriver and msedgedriver
Cache time will be respected as long as a driver binary exists and the major.minor.build versions of
the browser and the driver match. For example, if you update Chrome or Edge to v76.0.123 and its driver is
still at v76.0.100, webdrivers will ignore the cache time and update the driver to make sure you're
using a compatible build version.
Proxy
If there is a proxy between you and the Internet then you will need to configure
the gem to use the proxy. You can do this by calling the configure method.
Webdrivers.configure do |config|
config.proxy_addr = 'myproxy_address.com'
config.proxy_port = '8080'
config.proxy_user = 'username'
config.proxy_pass = 'password'
end
SSL_connect errors
If you are getting an error like this (especially common on Windows):
SSL_connect returned=1 errno=0 state=SSLv3 read server certificate B: certificate verify failed
Add the following to your Gemfile:
gem "net_http_ssl_fix"
Add the following to your code:
require 'net_http_ssl_fix'
Other solutions are documented on the RubyGems website.
Rake tasks
Each driver has its own set of rake tasks (with Railtie support) that
you can call once before executing the tests. These are especially
useful if you're running tests in parallel and want to avoid performing
an update check per thread.
If you are using Rails default configuration the webdrivers gem will only be loaded in the test group
so you will need to specify the test environment when using the tasks:
RAILS_ENV=test rails webdrivers:chromedriver:update
If you are not using Rails, you'll need to load them into your Rakefile like this:
require 'webdrivers'
load 'webdrivers/Rakefile'
The full list of available tasks is:
$ bundle exec rake -T
rake webdrivers:chromedriver:remove # Force remove chromedriver
rake webdrivers:chromedriver:update[version] # Remove and download updated chromedriver if necessary
rake webdrivers:chromedriver:version # Print current chromedriver version
rake webdrivers:edgedriver:remove # Force remove msedgedriver
rake webdrivers:edgedriver:update[version] # Remove and download updated msedgedriver if necessary
rake webdrivers:edgedriver:version # Print current msedgedriver version
rake webdrivers:geckodriver:remove # Force remove geckodriver
rake webdrivers:geckodriver:update[version] # Remove and download updated geckodriver if necessary
rake webdrivers:geckodriver:version # Print current geckodriver version
rake webdrivers:iedriver:remove # Force remove IEDriverServer
rake webdrivers:iedriver:update[version] # Remove and download updated IEDriverServer if necessary
rake webdrivers:iedriver:version # Print current IEDriverServer version
These tasks respect the WD_INSTALL_DIR, WD_CACHE_TIME, WD_CHROME_PATH,
and WD_EDGE_CHROME_PATH environment variables, which can also be passed
through the rake command:
$ bundle exec rake webdrivers:chromedriver:update[2.46] webdrivers:geckodriver:update[0.24.0] WD_CACHE_TIME=86_400 WD_INSTALL_DIR='my_dir'
2019-05-20 19:03:01 INFO Webdrivers Updated to chromedriver 2.46.628388
2019-05-20 19:03:04 INFO Webdrivers Updated to geckodriver 0.24.0
Please note that these tasks do not use any of the configurations from your
project (code) and only respect the ENV variables and the version (optional)
passed to the rake tasks.
Logging
The logging level can be configured for debugging purpose:
Webdrivers.logger.level = :DEBUG
Browser & OS Specific Notes
Chrome/Chromium
The version of chromedriver will depend on the version of Chrome you are using it with:
- For versions >= 70, the downloaded version of
chromedriverwill match the installed version of Google Chrome.
More information here. - For versions <= 69,
chromedriverversion 2.41 will be downloaded. - For beta versions, you'll have to require the beta version of
chromedriver
usingWebdrivers::Chromedriver.required_version.
The gem looks for the Chrome/Chromium version that chromedriver will use by default.
You can override this behavior by providing a path to the browser binary you want to use:
Selenium::WebDriver::Chrome.path = '/chromium/install/path/to/binary'
Alternatively, you can define the path via the WD_CHROME_PATH environment
variable.
This is also required if Google Chrome is not installed in its
default location.
Chrome on Heroku
Follow the specific instructions here if you're using heroku-buildpack-google-chrome.
Microsoft Edge (Chromium)
Microsoft Edge (Chromium) support was added in v4.1.0. Notes
from the Chrome/Chromium
section apply to this browser as well.
Please note that msedgedriver requires selenium-webdriver v4.
WSLv1 support
While WSLv1 is not designed to run headful applications like Chrome, it can run exes; as such when found to be running
in WSL, webdrivers will use Chrome on the Windows filesystem.
It's recommended that you install the new PowerShell (PS7) to avoid a known issue
with the console font being changed when calling the old PowerShell (PS5).
WSLv2 support
Webdrivers will detect WSLv2 as running on Linux and use Chrome on the Linux filesystem.
WSLv2 doesn't support connecting to host ports out of the box, so it isn't possible to connect to Chromedriver on
Windows without extra configurations, see: https://github.com/microsoft/WSL/issues/4619. The simplest way to use
Chromedriver with WSLv2 is to run Chrome headless on Linux.
Chrome and Edge on Apple M1 (arm64)
If you're switching from Intel to M1, you'll have to manually delete the existing Intel (mac64) driver before the
M1 (arm64) build can be downloaded. Otherwise, you'll get an error: Bad CPU type in executable - ~/.webdrivers/chromedriver (Errno::E086)
Wiki
Please see the wiki
for solutions to commonly reported issues.
Join us in the #webdrivers-gem channel on Slack
if you have any questions.
License
The gem is available as open source under the terms of the MIT License,
see LICENSE.txt for full details and copyright.
Contributing
Bug reports and pull requests are welcome on GitHub.
Run bundle exec rake and squash the commits in your PRs.
Owner metadata
- Name: Titus Fortner
- Login: titusfortner
- Email:
- Kind: user
- Description: A (mostly Ruby) open source developer (Selenium, Watir, etc); passionate about digital confidence & improving test automation success.
- Website: http://titusfortner.com
- Location: Austin, TX
- Twitter: titusfortner
- Company: Sauce Labs
- Icon url: https://avatars.githubusercontent.com/u/777185?u=e5302080954a8a1359f488ea8edec1ce2acf661c&v=4
- Repositories: 99
- Last ynced at: 2024-04-14T22:06:33.709Z
- Profile URL: https://github.com/titusfortner
GitHub Events
Total
- Watch event: 6
- Fork event: 1
Last Year
- Watch event: 5
Committers metadata
Last synced: 1 day ago
Total Commits: 274
Total Committers: 35
Avg Commits per committer: 7.829
Development Distribution Score (DDS): 0.595
Commits in past year: 0
Committers in past year: 0
Avg Commits per committer in past year: 0.0
Development Distribution Score (DDS) in past year: 0.0
| Name | Commits | |
|---|---|---|
| Titus Fortner | t****r@g****m | 111 |
| Lakshya Kapoor | k****a@g****m | 100 |
| Thomas Walpole | t****e@g****m | 19 |
| Utkarsh Gupta | u****h@d****g | 4 |
| Aleksei Gusev | a****v@g****m | 3 |
| Jeffrey S. Morgan | j****n@l****m | 3 |
| ochko | o****l@r****m | 2 |
| Stephen | s****n@e****m | 2 |
| Jeremiah | j****h@e****m | 2 |
| Jay McCure | j****e@g****m | 2 |
| Gareth Jones | J****8@G****m | 2 |
| ANSHIKA-26 | 1****6 | 1 |
| Akira Matsuda | r****e@d****p | 1 |
| Dan Jensen | D****n@A****o | 1 |
| Eduardo Gutierrez | e****o@r****m | 1 |
| François Leurent | 1****s@c****g | 1 |
| Fábio Gomes | f****n@g****m | 1 |
| yuuji.yaginuma | y****a@g****m | 1 |
| sadahiro-ono | s****o@r****m | 1 |
| runephilosof-abtion | 5****n | 1 |
| rhymes | r****e@g****m | 1 |
| Yasuo Honda | y****a@g****m | 1 |
| Tietew | t****w@g****m | 1 |
| Stephann Vasconcelos | 3****v | 1 |
| Samuel Williams | s****s@o****z | 1 |
| Ross Kaffenberger | r****f@g****m | 1 |
| Robert Clark | r****v@g****m | 1 |
| Robert Buchholz | r****u@g****e | 1 |
| Rich Downie | r****h@b****m | 1 |
| Peter Goldstein | p****n@g****m | 1 |
| and 5 more... | ||
Committer domains:
- webit.de: 1
- orien.io: 1
- blackboxd.com: 1
- goodpoint.de: 1
- oriontransfer.co.nz: 1
- rakuten.com: 1
- cloudyks.org: 1
- reversethreaded.com: 1
- addfour.co: 1
- dio.jp: 1
- entretechno.com: 1
- egroat.com: 1
- reallyenglish.com: 1
- leandog.com: 1
- debian.org: 1
Issue and Pull Request metadata
Last synced: about 2 months ago
Total issues: 73
Total pull requests: 42
Average time to close issues: about 2 months
Average time to close pull requests: 27 days
Total issue authors: 66
Total pull request authors: 29
Average comments per issue: 5.78
Average comments per pull request: 2.31
Merged pull request: 29
Bot issues: 0
Bot pull requests: 0
Past year issues: 0
Past year pull requests: 0
Past year average time to close issues: N/A
Past year average time to close pull requests: N/A
Past year issue authors: 0
Past year pull request authors: 0
Past year average comments per issue: 0
Past year average comments per pull request: 0
Past year merged pull request: 0
Past year bot issues: 0
Past year bot pull requests: 0
Top Issue Authors
- kapoorlakshya (6)
- luke-hill (3)
- dillonbarker-te (1)
- eliotsykes (1)
- ryanb (1)
- mockdeep (1)
- ericramsey (1)
- davetron5000 (1)
- jdelStrother (1)
- darinwilson (1)
- josh-m-sharpe (1)
- ChandrasekarGenesys (1)
- mileslane (1)
- ioquatix (1)
- hirowatari (1)
Top Pull Request Authors
- entretechno-jeremiah (3)
- titusfortner (3)
- utkarsh2102 (3)
- kapoorlakshya (3)
- G-Rath (2)
- fabioxgn (2)
- stephannv (2)
- sadahiro-ono (2)
- jmccure (2)
- MichaelHoste (1)
- runephilosof-abtion (1)
- zmariscal (1)
- y-yagi (1)
- 131 (1)
- okuramasafumi (1)
Top Issue Labels
- enhancement (1)
Top Pull Request Labels
Package metadata
- Total packages: 2
-
Total downloads:
- rubygems: 161,117,703 total
- Total docker downloads: 441,511,606
- Total dependent packages: 173 (may contain duplicates)
- Total dependent repositories: 115,080 (may contain duplicates)
- Total versions: 128
- Total maintainers: 3
gem.coop: webdrivers
Run Selenium tests more easily with install and updates for all supported webdrivers.
- Homepage: https://github.com/titusfortner/webdrivers
- Documentation: http://www.rubydoc.info/gems/webdrivers/
- Licenses: MIT
- Latest release: 5.3.1 (published over 2 years ago)
- Last Synced: 2026-01-09T19:20:56.689Z (about 7 hours ago)
- Versions: 64
- Dependent Packages: 0
- Dependent Repositories: 0
- Downloads: 80,585,142 Total
- Docker Downloads: 220,755,803
-
Rankings:
- Dependent repos count: 0.0%
- Dependent packages count: 0.0%
- Average: 0.21%
- Downloads: 0.357%
- Docker downloads count: 0.483%
- Maintainers (3)
rubygems.org: webdrivers
Run Selenium tests more easily with install and updates for all supported webdrivers.
- Homepage: https://github.com/titusfortner/webdrivers
- Documentation: http://www.rubydoc.info/gems/webdrivers/
- Licenses: MIT
- Latest release: 5.3.1 (published over 2 years ago)
- Last Synced: 2026-01-07T21:02:41.957Z (2 days ago)
- Versions: 64
- Dependent Packages: 173
- Dependent Repositories: 115,080
- Downloads: 80,532,561 Total
- Docker Downloads: 220,755,803
-
Rankings:
- Dependent repos count: 0.114%
- Dependent packages count: 0.209%
- Downloads: 0.318%
- Docker downloads count: 0.595%
- Average: 1.015%
- Stargazers count: 2.355%
- Forks count: 2.499%
- Maintainers (3)
Dependencies
- ffi ~> 1.0 development
- rake ~> 12.0 development
- rspec ~> 3.0 development
- rubocop ~> 0.89 development
- rubocop-packaging ~> 0.5.0 development
- rubocop-performance >= 0 development
- rubocop-rspec ~> 1.42 development
- simplecov ~> 0.16 development
- nokogiri ~> 1.6
- rubyzip >= 1.3.0
- selenium-webdriver ~> 4.0
- actions/checkout v2 composite
- ruby/setup-ruby v1 composite
- styfle/cancel-workflow-action 0.7.0 composite
Score: 30.170948440992035