Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

app demo can't run in Android 23 emulator #223

Closed
jiyewushen opened this issue Oct 16, 2024 · 6 comments
Closed

app demo can't run in Android 23 emulator #223

jiyewushen opened this issue Oct 16, 2024 · 6 comments

Comments

@jiyewushen
Copy link

About this issue

  • Briefly describe the issue
  • How can the issue be reproduced / sample code

Details

  • develop branch,no change
  • [Ladybug 2024.2.1 Patch 1 ] Used tooling / Android Studio version

//test android 24 & android 34,no error.
//test android 21 & android 23,same error.

java.lang.NoSuchMethodError: No static method addRoundRect$default(Landroidx/compose/ui/graphics/Path;Landroidx/compose/ui/geometry/RoundRect;Landroidx/compose/ui/graphics/Path$Direction;ILjava/lang/Object;)V in class Landroidx/compose/ui/graphics/Path; or its super classes (declaration of 'androidx.compose.ui.graphics.Path' appears in /data/app/com.mikepenz.markdown-2/base.apk)

image

when add next config on multiplatform-mark-renderer module build.gradle.kts,app now work well at android 21 (include android 23).

kotlin {
    //...
    sourceSets {
        //...
        val commonMain by getting {
            dependencies {
                //only add this
                implementation(compose.foundation)
            }
        }
    }
}
@mikepenz
Copy link
Owner

please make sure you use compose 1.7 or newer

@jiyewushen
Copy link
Author

please make sure you use compose 1.7 or newer

Maybe my description wasn't accurate enough. All code is from the develop branch of the current project and I have not made any changes. Just run the app module on the official android emulator (api 21 or api 23),then the above error occurs. I have also confirmed that Compose Version is 1.7.3.

@keta1
Copy link
Contributor

keta1 commented Oct 29, 2024

The cause of this carsh is Default methods require API level 24.
Maybe this problem will be solved when desuagr is enabled.

@mikepenz
Copy link
Owner

mikepenz commented Nov 1, 2024

Attempted to enable desugaring, but it didn't seem to fix it.

That said. this seems to be from compose, and not from this library itself. Will update the sample app to min API 24 though to be more clear on this.

@mikepenz
Copy link
Owner

mikepenz commented Nov 1, 2024

If someone has some more resources to look into to address this, I'd be curious about it.
But so far I'll close this as it appears to be out of scope of the lib itself.

mikepenz added a commit that referenced this issue Nov 1, 2024
@mikepenz mikepenz closed this as not planned Won't fix, can't repro, duplicate, stale Nov 1, 2024
@keta1
Copy link
Contributor

keta1 commented Nov 1, 2024

If someone has some more resources to look into to address this, I'd be curious about it. But so far I'll close this as it appears to be out of scope of the lib itself.

I think need report this problem to Google, I will take the time to create a minimal reproduction example and submit it to Google

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants