Welcome to the new Parasoft forums! We hope you will enjoy the site and try out some of the new features, like sharing an idea you may have for one of our products or following a category.

Running Selenium Invalid Status code=403 Fix - Eclipse

[Deleted User]
[Deleted User] Posts: 0 admin
edited July 2023 in Selenic

If running Seleniums Tests in Selenic 2022.2 on Eclipse and encounter the following message:

Chrome version installed: 114.0.5735.99
Chrome driver installed: ChromeDriver 114.0.5735.90

This issue occurs with newer versions of Chrome as discussed here:
https://github.com/SeleniumHQ/selenium/issues/11750

Selenium 4.8.3 has a fix for this issue that affects the newer versions of Chrome and will not need to add “--remote-allow-origins=*” to the options, this was done to remedy the issue prior to Selenium 4.8.3.

Since Parasoft Selenic 2022.2 ships with selenium 4.7.2, a **solution **to this issue is to upgrade the Selenium Java Libraries (.jar files) from https://www.selenium.dev/downloads/ and replace the older Selenium jar files in the project.

At the time of this writing, we have verified selenium java libraries 4.10 worked successfully.

Please note these changes will persist for the project. However, the jar files will be required to remove/replaced again for newly created projects.

Steps to update Selenium Java Libraries in Selenic:

  1. Download the latest Selenium Java libraries (4.10) from https://github.com/SeleniumHQ/selenium/releases/download/selenium-4.10.0/selenium-java-4.10.0.zip
    --Can also be found here: https://www.selenium.dev/downloads/

  2. Extract the contents to the machine.

  3. In Eclipse, remove 4.7.2 jars and replace them with the updated 4.10 jar files.
    a) In Eclipse’s Package Explorer open Project and right-click “Referenced Libraries” > select “Build Path” > Configure Build Path

    b)To remove: ctrl shift select all selenium *4.7.2.jar files then select “Remove”

    c)To replace: in the same page scroll up and select "Classpath" > Add External Jars..

    d) Navigate to the extracted content (2) and select all selenium *4.10.0.jar files

    --Please note: *-source.jar files found in the extracted content (2) are not required and will take up data if added; however, adding will not affect the functionality.

    e) Select Apply and Close

  4. All done. Attempt to run tests as before.