healenium / healenium-web

Self-healing library for Selenium Web-based tests
Apache License 2.0
169 stars 40 forks source link

Getting java.lang.NoClassDefFoundError: org/openqa/selenium/interactions/Locatable #150

Closed sudiprai10 closed 3 years ago

sudiprai10 commented 3 years ago

HI, Can you please helping in understand why I am getting below error when I integrated Healenium with in framework. Please refer the screenshot.

image

ElenaStepuro commented 3 years ago

Hello @sudiprai10 ! Could you please provide more information?) Which healenium web and backend version do you use? Is this issue reproduced for all locators or for some specific?

sudiprai10 commented 3 years ago

Hello @sudiprai10 ! Could you please provide more information?) Which healenium web and backend version do you use? Is this issue reproduced for all locators or for some specific?

Hi @ElenaStepuro healenium web version is 3.1.4. Yes issue is reproduced for all locators.

ElenaStepuro commented 3 years ago

@sudiprai10 Looks like one of jar file is missing in your build path. I would recommend you to reimport all selenium related jars to your project, to make sure you wont be getting any such dependency issues down the line. Please, use latest selenium version, make sure you added all jars from selenium directory to your build path and rerun your project. In addition, I recommend to use healenium web version 3.1.6

sudiprai10 commented 3 years ago

@sudiprai10 Looks like one of jar file is missing in your build path. I would recommend you to reimport all selenium related jars to your project, to make sure you wont be getting any such dependency issues down the line. Please, use latest selenium version, make sure you added all jars from selenium directory to your build path and rerun your project. In addition, I recommend to use healenium web version 3.1.6

@ElenaStepuro all selenium related jars are added in the build path. Please refer the screenshot attached and let me know if I missed any and I am using lated version of healenium-web and healenium-backend but still problem persist.

image

ElenaStepuro commented 3 years ago

@sudiprai10 please, use selenium version 3.141.59 for all of these jars

sudiprai10 commented 3 years ago

@sudiprai10 please, use selenium version 3.141.59 for all of these jars

@ElenaStepuro Thanks for your input. It is working now.

Abhi01290 commented 1 year ago

I am getting the below error while trying to run the script

  java.lang.NoClassDefFoundError: org/openqa/selenium/support/locators/RelativeLocator$RelativeBy
at com.epam.healenium.mapper.HealeniumMapper.<init>(HealeniumMapper.java:44)
at com.epam.healenium.SelfHealingDriver.setEngineFields(SelfHealingDriver.java:55)
at com.epam.healenium.SelfHealingDriver.create(SelfHealingDriver.java:41)

I am using the following dependency version in POM.xml org.junit.jupiter:junit-jupiter-api: 5.9.3 org.junit.jupiter:junit-jupiter-engine: 5.9.3 org.seleniumhq.selenium:selenium-java: 3.141.59 io.github.bonigarcia:webdrivermanager: 5.4.1 healenium-web : 3.4.3

And I am using the below code WebDriverManager.chromedriver().setup(); WebDriver delegate = new ChromeDriver(); driver= SelfHealingDriver.create(delegate);

Please provide the resolution..

maysolan commented 11 months ago

I am getting the below error while trying to run the script

  java.lang.NoClassDefFoundError: org/openqa/selenium/support/locators/RelativeLocator$RelativeBy
at com.epam.healenium.mapper.HealeniumMapper.<init>(HealeniumMapper.java:44)
at com.epam.healenium.SelfHealingDriver.setEngineFields(SelfHealingDriver.java:55)
at com.epam.healenium.SelfHealingDriver.create(SelfHealingDriver.java:41)

I am using the following dependency version in POM.xml org.junit.jupiter:junit-jupiter-api: 5.9.3 org.junit.jupiter:junit-jupiter-engine: 5.9.3 org.seleniumhq.selenium:selenium-java: 3.141.59 io.github.bonigarcia:webdrivermanager: 5.4.1 healenium-web : 3.4.3

And I am using the below code WebDriverManager.chromedriver().setup(); WebDriver delegate = new ChromeDriver(); driver= SelfHealingDriver.create(delegate);

Please provide the resolution..

Did you receive any fix on this element issue?

umredkarabhijeet commented 2 months ago

Hi, I am getting following error on this line :-

driver = SelfHealingDriver.create(delegate);

java.lang.NoClassDefFoundError: org/openqa/selenium/interactions/HasInputDevices at com.epam.healenium.utils.ProxyFactory.createDriverProxy(ProxyFactory.java:35) at com.epam.healenium.SelfHealingDriver.create(SelfHealingDriver.java:45) at com.epam.healenium.SelfHealingDriver.create(SelfHealingDriver.java:34)

my selenium version is 4.11.0 and healenium-web is 3.2.0. Could someone help to fix above exception?

Abhi01290 commented 2 months ago

I am getting the below error while trying to run the script

  java.lang.NoClassDefFoundError: org/openqa/selenium/support/locators/RelativeLocator$RelativeBy
at com.epam.healenium.mapper.HealeniumMapper.<init>(HealeniumMapper.java:44)
at com.epam.healenium.SelfHealingDriver.setEngineFields(SelfHealingDriver.java:55)
at com.epam.healenium.SelfHealingDriver.create(SelfHealingDriver.java:41)

I am using the following dependency version in POM.xml org.junit.jupiter:junit-jupiter-api: 5.9.3 org.junit.jupiter:junit-jupiter-engine: 5.9.3 org.seleniumhq.selenium:selenium-java: 3.141.59 io.github.bonigarcia:webdrivermanager: 5.4.1 healenium-web : 3.4.3 And I am using the below code WebDriverManager.chromedriver().setup(); WebDriver delegate = new ChromeDriver(); driver= SelfHealingDriver.create(delegate); Please provide the resolution..

Did you receive any fix on this element issue?

Yes, I resolved this error. First, you need to install Selenium version 4.0 or above, and then ensure you have the Maven plugin for Healenium. For a step-by-step guide, visit this site: https://healenium.io/docs/overview.

Abhi01290 commented 2 months ago

Hi, I am getting following error on this line :-

driver = SelfHealingDriver.create(delegate);

java.lang.NoClassDefFoundError: org/openqa/selenium/interactions/HasInputDevices at com.epam.healenium.utils.ProxyFactory.createDriverProxy(ProxyFactory.java:35) at com.epam.healenium.SelfHealingDriver.create(SelfHealingDriver.java:45) at com.epam.healenium.SelfHealingDriver.create(SelfHealingDriver.java:34)

my selenium version is 4.11.0 and healenium-web is 3.2.0. Could someone help to fix above exception?

Yes, I resolved this error. First, you need to install Selenium version 4.0 or above, and then ensure you have the Maven plugin for Healenium. For a step-by-step guide, visit this site: https://healenium.io/docs/overview.