question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Can't make Appium work with Compose 1.2.0 - java.lang.AbstractMethodError: abstract method "kotlin.coroutines.CoroutineContext$Key androidx.compose.ui.platform.InfiniteAnimationPolicy.getKey()"

See original GitHub issue

I’m using latest beta versions of appium (Appium v2.0.0-beta.42) and espresso driver, but I can’t make it work with compose app. I’ve tried even on empty compose Hello world project generated by Android studio (using compose version 1.2.0), but the appium still throws this error:

[debug] [EspressoDriver@d452 (d7e46f24)] [Instrumentation] io.appium.espressoserver.EspressoServerRunnerTest: [debug] [EspressoDriver@d452 (d7e46f24)] [Instrumentation] Error in startEspressoServer(io.appium.espressoserver.EspressoServerRunnerTest): [debug] [EspressoDriver@d452 (d7e46f24)] java.lang.AbstractMethodError: abstract method "kotlin.coroutines.CoroutineContext$Key androidx.compose.ui.platform.InfiniteAnimationPolicy.getKey()" [debug] [EspressoDriver@d452 (d7e46f24)] at kotlin.coroutines.CoroutineContext$plus$1.invoke(CoroutineContext.kt:33) [debug] [EspressoDriver@d452 (d7e46f24)] at kotlin.coroutines.CoroutineContext$plus$1.invoke(CoroutineContext.kt:32) [debug] [EspressoDriver@d452 (d7e46f24)] at kotlin.coroutines.CoroutineContext$Element$DefaultImpls.fold(CoroutineContext.kt:70) [debug] [EspressoDriver@d452 (d7e46f24)] at androidx.compose.ui.platform.InfiniteAnimationPolicy$DefaultImpls.fold(InfiniteAnimationPolicy.kt:36) [debug] [EspressoDriver@d452 (d7e46f24)] at androidx.compose.ui.test.AndroidComposeUiTestEnvironment$infiniteAnimationPolicy$1.fold(ComposeUiTest.android.kt:239) [debug] [EspressoDriver@d452 (d7e46f24)] at kotlin.coroutines.CoroutineContext$DefaultImpls.plus(CoroutineContext.kt:32) [debug] [EspressoDriver@d452 (d7e46f24)] at kotlin.coroutines.CombinedContext.plus(CoroutineContextImpl.kt:111) [debug] [EspressoDriver@d452 (d7e46f24)] at androidx.compose.ui.test.AndroidComposeUiTestEnvironment.<init>(ComposeUiTest.android.kt:248) [debug] [EspressoDriver@d452 (d7e46f24)] at androidx.compose.ui.test.junit4.AndroidComposeTestRule$special$$inlined$AndroidComposeUiTestEnvironment$1.<init>(ComposeUiTest.android.kt:203) [debug] [EspressoDriver@d452 (d7e46f24)] at androidx.compose.ui.test.junit4.AndroidComposeTestRule.<init>(AndroidComposeTestRule.android.kt:212) [debug] [EspressoDriver@d452 (d7e46f24)] at io.appium.espressoserver.EspressoServerRunnerTest.<init>(EspressoServerRunnerTest.kt:45)

Did anyone make appium espresso work with Compose?

Issue Analytics

  • State:open
  • Created a year ago
  • Reactions:9
  • Comments:17 (6 by maintainers)

github_iconTop GitHub Comments

1reaction
KazuCocoacommented, Nov 8, 2022

The build itself seems ok, the above behavior is expected

1reaction
chrisjenxcommented, Oct 19, 2022

I fixed this by forcing androidx.compose.ui to 1.2.1, looks like there was a dependency conflict between testing and runtime deps

Read more comments on GitHub >

github_iconTop Results From Across the Web

No results found

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found