3

Setting up appium on my new mac. When executed a Test am seeing below error,

java.lang.RuntimeException: java.lang.NoSuchMethodException: jdk.proxy2.$Proxy15.proxyClassLookup() at io.appium.java_client.pagefactory.bys.builder.AppiumByBuilder.prepareAnnotationMethods(AppiumByBuilder.java:85) at io.appium.java_client.pagefactory.bys.builder.AppiumByBuilder.getFilledValue(AppiumByBuilder.java:92) at io.appium.java_client.pagefactory.bys.builder.AppiumByBuilder.createBy(AppiumByBuilder.java:148) at io.appium.java_client.pagefactory.DefaultElementByBuilder.getBys(DefaultElementByBuilder.java:133) at io.appium.java_client.pagefactory.DefaultElementByBuilder.buildMobileNativeBy(DefaultElementByBuilder.java:182) at io.appium.java_client.pagefactory.DefaultElementByBuilder.buildBy(DefaultElementByBuilder.java:216) at io.appium.java_client.pagefactory.AppiumElementLocatorFactory.createLocator(AppiumElementLocatorFactory.java:66) at io.appium.java_client.pagefactory.AppiumElementLocatorFactory.createLocator(AppiumElementLocatorFactory.java:53) at io.appium.java_client.pagefactory.AppiumElementLocatorFactory.createLocator(AppiumElementLocatorFactory.java:1) at org.openqa.selenium.support.pagefactory.DefaultFieldDecorator.decorate(DefaultFieldDecorator.java:56) at io.appium.java_client.pagefactory.AppiumFieldDecorator.decorate(AppiumFieldDecorator.java:155) at org.openqa.selenium.support.PageFactory.proxyFields(PageFactory.java:113) at org.openqa.selenium.support.PageFactory.initElements(PageFactory.java:105)

JAVA VERSION: java version "15.0.2" 2021-01-19 Java(TM) SE Runtime Environment (build 15.0.2+7-27)

Appium Desktop Version: 1.20.2

<groupId>io.appium</groupId>
<artifactId>java-client</artifactId>
<version>7.0.0</version>
KALYAN
  • 31
  • 3

2 Answers2

6

I fixed this situation by changing from Java SE 17.0.1 to Java SE 11.0.12. Please, see the following picture. Press here to see the change in Elipse IDE

0

Try mvn clean install, if it doesn't help try reset cache in Intellij

Marek Borecki
  • 402
  • 1
  • 4
  • 20