

The output should be something like this: Google Chrome. Note that those escaped spaces are important (\ ). Getting the current version of Chrome using the TerminalĪssuming that you are on a Mac and have simply installed Chrome into your Applications folder, you can actually get your Chrome version by throwing this into your terminal: /Applications/Google\ Chrome.app/Contents/MacOS/Google\ Chrome -version The manual way takes way too long, though.


First thing to do is get the version of Chrome that I have on my computer. This became my roadmap for how to structure my script. I discovered this awesome guide to selecting the right chromedriver version here on their site: Shell Script to Download the Correct File That way we simply download the chromedriver into the same directory and we know that the script will be there, bundled together. I am keeping it simple by saving this shell script in the same path as my current chromedriver. (If you're comfortable with shell scripts or just want to cut to the chase, get the full script at the bottom-and the video version is down there, too) Where to Save the Script and the chromedriver File I have to find out which version of chromedriver I need, download the file, unzip, and clean up my workspace. Normally to fix this error: : Message: session not created: This version of ChromeDriver only supports Chrome version 97 Let us now check out the steps to download ChromeDriver.I'm really tired of opening up a script to run some monthly reports, only to find that Chrome has updated again, which means my chromedriver breaks my script. Source: StatCounter Global Stats – Browser Market Share But now a lot of people prefer to use chrome to write automation scripts. When I started working on Selenium automation in 2012 Firefox was kind of the default browser to go to when people wanted to automate test scripts.

So, it makes sense to work on the browser which majority of the people are using.
