Chaintech-Network / ComposeMultiplatformMediaPlayer

Apache License 2.0
326 stars 22 forks source link

Cannot access class 'com.google.common.util.concurrent.ListenableFuture'. Check your module classpath for missing or conflicting dependencies. #34

Open rafaelmfer opened 5 days ago

rafaelmfer commented 5 days ago

Using this implementation("network.chaintech:compose-multiplatform-media-player:1.0.26") or this version implementation("network.chaintech:compose-multiplatform-media-player:1.0.16")

Syncs perfectly but when I run the project I got this error

image

I'm using KMP and CMP. I'm using the camera library on Android, and then I got this error.

Here it is all my libraries and versions:

[versions]
android-compileSdk = "34"
android-minSdk = "24"
android-targetSdk = "34"

agp = "8.5.2"
kotlin = "2.0.21"

# Camera Android
cameraCore = "1.4.0"
faceDetection = "16.1.7"

# AndroidX Core
core-ktx = "1.13.1"
core-splash-screen = "1.1.0-rc01"

# Google
googleGms = "4.4.2"
googleKsp = "2.0.20-1.0.24"

# Design
androidx-appcompat = "1.7.0"
androidx-material = "1.12.0"
androidx-constraintlayout = "2.2.0"
androidx-lifecycle = "2.8.3"
androidx-activityCompose = "1.9.3"
compose = "1.7.0"
navigationCompose = "2.8.0-alpha10"
constraintlayoutComposeMultiplatform = "0.5.0-alpha03-shaded-core"
cmptoast = "1.0.1"
landscapistCoil3 = "2.4.0"
compottie="2.0.0-rc02"

# Library for Date and Time
date-time = "0.6.1"

# Koin - Dependecy Injection
koin = "4.0.0"

# Coroutines - Asynchronous calls
coroutines = "1.9.0"

# Ktorfit & Ktor - Network
ktor = "3.0.0-rc-1" #Before: "2.3.12"
ktorfitVersion = "2.1.0"

# BuildConfig
build-config = "5.5.0"

# Serialization
kotlinx-serialization = "1.7.3"

# KMP Push Notifications
kmp-notifier = "1.2.1"
uuid = "0.8.4"

# KVault
kvault = "1.12.0"

# KMP Auth
kmpauth = "2.1.0"

# Permissions KMP Moko
permissionsCompose = "0.18.1"

# iOS - Cinterop
swiftKlib = "0.6.4"

# Tests
androidx-espresso-core = "3.6.1"
androidx-test-junit = "1.2.1"
junit = "4.13.2"

# Android Wearable
playServicesWearable = "18.2.0"
composeBom = "2024.10.01"
composeMaterial = "1.0.0-alpha28"
composeFoundation = "1.4.0"
wearToolingPreview = "1.0.0"

[libraries]
androidx-core-ktx = { group = "androidx.core", name = "core-ktx", version.ref = "core-ktx" }
androidx-core-splashscreen = { group = "androidx.core", name = "core-splashscreen", version.ref = "core-splash-screen" }

# Design
androidx-appcompat = { group = "androidx.appcompat", name = "appcompat", version.ref = "androidx-appcompat" }
androidx-material = { group = "com.google.android.material", name = "material", version.ref = "androidx-material" }
androidx-constraintlayout = { group = "androidx.constraintlayout", name = "constraintlayout", version.ref = "androidx-constraintlayout" }
androidx-activity-compose = { module = "androidx.activity:activity-compose", version.ref = "androidx-activityCompose" }
androidx-lifecycle-viewmodel = { group = "org.jetbrains.androidx.lifecycle", name = "lifecycle-viewmodel", version.ref = "androidx-lifecycle" }
androidx-lifecycle-runtime-compose = { group = "org.jetbrains.androidx.lifecycle", name = "lifecycle-runtime-compose", version.ref = "androidx-lifecycle" }
androidx-lifecycle-viewmodel-compose = { group = "org.jetbrains.androidx.lifecycle", name = "lifecycle-viewmodel-compose", version.ref = "androidx-lifecycle" }
constraintlayout-compose-multiplatform = { module = "tech.annexflow.compose:constraintlayout-compose-multiplatform", version.ref = "constraintlayoutComposeMultiplatform" }
navigation-compose = { module = "org.jetbrains.androidx.navigation:navigation-compose", version.ref = "navigationCompose" }
cmptoast = { module = "network.chaintech:cmptoast", version.ref = "cmptoast" }
# Coil - image-loading library
landscapist-coil3 = { module = "com.github.skydoves:landscapist-coil3", version.ref = "landscapistCoil3" }

# Compottie - Lottie library
compottie = { module = "io.github.alexzhirkevich:compottie", version.ref = "compottie" }
compottie-dot = { module = "io.github.alexzhirkevich:compottie-dot", version.ref = "compottie" }
compottie-network = { module = "io.github.alexzhirkevich:compottie-network", version.ref = "compottie" }
compottie-resources = { module = "io.github.alexzhirkevich:compottie-resources", version.ref = "compottie" }

# Library for Date and Time
kotlinx-datetime = { module = "org.jetbrains.kotlinx:kotlinx-datetime", version.ref = "date-time" }

# Koin - Dependecy Injection
koin-android = { module = "io.insert-koin:koin-android", version.ref = "koin" }
koin-core = { module = "io.insert-koin:koin-core", version.ref = "koin" }
koin-compose = { module = "io.insert-koin:koin-compose", version.ref = "koin" }
koin-compose-viewmodel = { module = "io.insert-koin:koin-compose-viewmodel", version.ref = "koin" }
koin-compose-viewmodel-navigation = { module = "io.insert-koin:koin-compose-viewmodel-navigation", version.ref = "koin" }

# Coroutines - Asynchronous calls
kotlinx-coroutines-core = { module = "org.jetbrains.kotlinx:kotlinx-coroutines-core", version.ref = "coroutines" }
kotlinx-coroutines-android = { module = "org.jetbrains.kotlinx:kotlinx-coroutines-android", version.ref = "coroutines" }

# Ktorfit - Similar Retrofit - Network
ktorfit = { module = "de.jensklingenberg.ktorfit:ktorfit-lib", version.ref = "ktorfitVersion" }

# Ktor - Network
ktor-client-content-negotiation = { module = "io.ktor:ktor-client-content-negotiation", version.ref = "ktor" }
ktor-serialization-kotlinx-json = { module = "io.ktor:ktor-serialization-kotlinx-json", version.ref = "ktor" }
ktor-client-core = { module = "io.ktor:ktor-client-core", version.ref = "ktor" }
ktor-client-darwin = { module = "io.ktor:ktor-client-darwin", version.ref = "ktor" }
ktor-client-logging = { module = "io.ktor:ktor-client-logging", version.ref = "ktor" }
ktor-client-android = { module = "io.ktor:ktor-client-android", version.ref = "ktor" }

# Serialization
kotlinx-serialization-json = { module = "org.jetbrains.kotlinx:kotlinx-serialization-json", version.ref = "kotlinx-serialization" }

# Kvault - Secure Encrypted Storage
kvault = { module = "com.liftric:kvault", version.ref = "kvault" }

# KMP Notifications
kmpnotifier = { module = "io.github.mirzemehdi:kmpnotifier", version.ref = "kmp-notifier" }
kmpnotifier-benasher44uuid = { module = "com.benasher44:uuid", version.ref = "uuid" }

# KMP Auth
kmpauth-firebase = { module = "io.github.mirzemehdi:kmpauth-firebase", version.ref = "kmpauth" }
kmpauth-google = { module = "io.github.mirzemehdi:kmpauth-google", version.ref = "kmpauth" }
kmpauth-uihelper = { module = "io.github.mirzemehdi:kmpauth-uihelper", version.ref = "kmpauth" }

# KMP Permissions - Moko
permissions = { module = "dev.icerock.moko:permissions-compose", version.ref = "permissionsCompose" }

## Android
# Camera X
androidx-camera-camera2 = { module = "androidx.camera:camera-camera2", version.ref = "cameraCore" }
androidx-camera-core = { module = "androidx.camera:camera-core", version.ref = "cameraCore" }
androidx-camera-lifecycle = { module = "androidx.camera:camera-lifecycle", version.ref = "cameraCore" }
androidx-camera-view = { module = "androidx.camera:camera-view", version.ref = "cameraCore" }

# ML Kit
face-detection = { module = "com.google.mlkit:face-detection", version.ref = "faceDetection" }

## Android Wearable Libs
play-services-wearable = { group = "com.google.android.gms", name = "play-services-wearable", version.ref = "playServicesWearable" }
androidx-compose-bom = { group = "androidx.compose", name = "compose-bom", version.ref = "composeBom" }
androidx-ui = { group = "androidx.compose.ui", name = "ui" }
androidx-ui-graphics = { group = "androidx.compose.ui", name = "ui-graphics" }
androidx-ui-tooling = { group = "androidx.compose.ui", name = "ui-tooling" }
androidx-ui-tooling-preview = { group = "androidx.compose.ui", name = "ui-tooling-preview" }

wear-compose-material = { group = "androidx.wear.compose", name = "compose-material3", version.ref = "composeMaterial" }
wear-compose-foundation = { group = "androidx.wear.compose", name = "compose-foundation", version.ref = "composeFoundation" }
wear-tooling-preview = { group = "androidx.wear", name = "wear-tooling-preview", version.ref = "wearToolingPreview" }

## Libraries for Tests
kotlin-test = { module = "org.jetbrains.kotlin:kotlin-test", version.ref = "kotlin" }
kotlin-test-junit = { module = "org.jetbrains.kotlin:kotlin-test-junit", version.ref = "kotlin" }
junit = { group = "junit", name = "junit", version.ref = "junit" }
androidx-test-junit = { group = "androidx.test.ext", name = "junit", version.ref = "androidx-test-junit" }
androidx-espresso-core = { group = "androidx.test.espresso", name = "espresso-core", version.ref = "androidx-espresso-core" }
kotlinx-coroutines-test = { module = "org.jetbrains.kotlinx:kotlinx-coroutines-test", version.ref = "coroutines" }
androidx-ui-test-manifest = { group = "androidx.compose.ui", name = "ui-test-manifest" }
androidx-ui-test-junit4 = { group = "androidx.compose.ui", name = "ui-test-junit4" }

[plugins]
kotlinMultiplatform = { id = "org.jetbrains.kotlin.multiplatform", version.ref = "kotlin" }
kotlin-android = { id = "org.jetbrains.kotlin.android", version.ref = "kotlin" }
androidApplication = { id = "com.android.application", version.ref = "agp" }
androidLibrary = { id = "com.android.library", version.ref = "agp" }

# Google
ksp = { id = "com.google.devtools.ksp", version.ref = "googleKsp" }
google-gms = {id = "com.google.gms.google-services", version.ref = "googleGms"}

# Compose
jetbrainsCompose = { id = "org.jetbrains.compose", version.ref = "compose" }
compose-compiler = { id = "org.jetbrains.kotlin.plugin.compose", version.ref = "kotlin" }

# Ktorfit - Network
ktorfit = { id = "de.jensklingenberg.ktorfit", version.ref = "ktorfitVersion" }

# Serialization
kotlinx-serialization = { id = "org.jetbrains.kotlin.plugin.serialization", version.ref = "kotlin" }

# BuildConfig
buildConfig = {id = "com.github.gmazzo.buildconfig", version.ref = "build-config" }

# iOS - cinterop
swiftKlib = { id = "io.github.ttypic.swiftklib", version.ref = "swiftKlib" }
rafaelmfer commented 5 hours ago

It seems like there is a conflict with the camera dependency from google CameraX:

androidx-camera-camera2 = { module = "androidx.camera:camera-camera2", version.ref = "cameraCore" } androidx-camera-core = { module = "androidx.camera:camera-core", version.ref = "cameraCore" } androidx-camera-lifecycle = { module = "androidx.camera:camera-lifecycle", version.ref = "cameraCore" } androidx-camera-view = { module = "androidx.camera:camera-view", version.ref = "cameraCore" }