Chrome Driver Version 81 not found

38 views
Skip to first unread message

Shreya J

unread,
Jun 11, 2020, 10:41:43 AM6/11/20
to Geb User Mailing List
Hi, 

I have a couple of questions regarding the github code. I am just trying to run the code as is to initially get an idea of whats going on. I cloned the repository and tried running ./gradlew chromeTest but my Chrome version is 81. I updated the driver version in the build.gradle file based on the driver version for Chrome version 81 but I get an error that the DriverURL is not found.
> com.github.erdi.gradle.webdriver.repository.DriverUrlNotFoundException: Driver url not found for name: "chromedriver", version: "81.0.4044.138", platform: "mac", bit: "64 or 32"

Do I need to specify this as an environment variable or something for my IDE to know that I did download the chromeDriver with that version specified? 

Thanks

Thomas Hirsch

unread,
Jun 11, 2020, 10:51:04 AM6/11/20
to Geb User Mailing List
Hi Schreya, 
when exactly do you get that error? You mention that you are running `./gradlew chromeTest` but you also mention your IDE.

Generally what you are doing seems correct,you should set the desired driver version, matching your browsers version, in the `build.gradle` file, and then execute the `configureChromeDriverBinary` task, e.g. `./gradlew configureChromeDriverBinary`. This task should also get executed when you run `chromeTest`.

Best Regards,
Thomas

Shreya J

unread,
Jun 11, 2020, 10:58:21 AM6/11/20
to Geb User Mailing List
Hi Thomas, 

I get the error when I run `./gradlew chromeTest` in my IntelliJ terminal. Does the location of the download for the chrome driver matter? It's currently sitting in my downloads directory. 
Seems like it does error out on the `configureChromeDriverBinary` task which runs when I run `chromeTest`.  I don't see an issue when I run `firefoxTest` though.

When I run `chromeTest` with the project as is i.e with the version 79.0.3945.36 , I get an error as follows since I am on Chrome Version 81. 
 Caused by:
        org.openqa.selenium.SessionNotCreatedException: session not created: This version of ChromeDriver only supports Chrome version 79
        Build info: version: '3.14.0', revision: 'aacccce0', time: '2018-08-02T20:19:58.91Z'


Thanks, 
Shreya

Thomas Hirsch

unread,
Jun 15, 2020, 4:30:32 AM6/15/20
to Geb User Mailing List
Hi Shreya,
if you are getting a "URL not found" error when choosing a different driver version, but it works with the original driver version, this strongly suggests that you have an error in the version number, or something like that, maybe an additional space or dot...
I am switching driver versions often, and never had that problem.
What operating system are you using by the way?

Best regards,
Thomas

varun jain

unread,
Jun 15, 2020, 8:15:35 AM6/15/20
to Geb User Mailing List
Hi Shreya,

One way to overcome this problem is to have chrome driver binary in the project and set the path to it in the project. 

Steps
  1. Update your Chrome to the latest version 83.0.43 as Chrome usually auto-updates
  2. Download the chrome driver binary for your browser ( Chrome 83.0.43...) in your system.  
  3. Put the binary somewhere in the resources /src/main/resources/browser-drivers/chromedrivermac
  4. In build.gradle you can set system property to define the path
    systemProperties = [
    macWebdriverChromeDriver    
    : "${rootPath}/src/main/resources/browser-drivers/chromedrivermac"
    ]

  5. In GebConfig.groovy, Set the path 
    def setDriverExec() {
       
    if (SystemUtils.IS_OS_MAC_OSX || SystemUtils.IS_OS_MAC) {
           
    System.setProperty("webdriver.chrome.driver", System.getProperty("macWebdriverChromeDriver"))
    }
    }

    Varun



Marcin Erdmann

unread,
Jun 15, 2020, 3:09:53 PM6/15/20
to geb-...@googlegroups.com
Hi Shreya,

On Mon, Jun 15, 2020 at 1:15 PM varun jain <varun...@gmail.com> wrote:
One way to overcome this problem is to have chrome driver binary in the project and set the path to it in the project. 

I would advise against doing so. One should not put binaries under source control, especially such that can be easily resolved by the build.

You are getting a DriverUrlNotFoundException because the version of chromedriver binary you used does not match one listed in https://github.com/webdriverextensions/webdriverextensions-maven-plugin-repository/blob/master/repository-3.0.json (see this section of the manual for Gradle webdriver binaries plugin to understand the significance of that file: https://github.com/erdi/webdriver-binaries-gradle-plugin/blob/master/README.md#configuring-download-urls). If your Chrome version is 81.0.4044.138 then you should use 81.0.4044.69 as the version of chromedriver binary.

Cheers,
Marcin

Shreya J

unread,
Jun 15, 2020, 4:21:59 PM6/15/20
to Geb User Mailing List
Marcin, that was indeed the case. Thank you! 

My chrome updated recently to 83 and I was able to use 83.0.4103.39 as listed on here for mac - https://github.com/webdriverextensions/webdriverextensions-maven-plugin-repository/blob/master/repository-3.0.json Thanks again for taking the time to respond and putting the links in the answer. They are very helpful.


- Shreya

Marcin Erdmann

unread,
Jun 16, 2020, 4:40:03 AM6/16/20
to geb-...@googlegroups.com
No worries, I'm glad my suggestion helped.

--
You received this message because you are subscribed to the Google Groups "Geb User Mailing List" group.
To unsubscribe from this group and stop receiving emails from it, send an email to geb-user+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/geb-user/7d28991f-87b1-45a3-b461-c1645ecc94a9o%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages