You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
Kind of like the same issue as #178 , but I wanted to create a new issue as it may be a little bit different.
I have multiple modules that are all using (for example) Ktor and I build all of them and upload them to Nexus. Once building my Android application it fails with "Duplicate class" for KoinDefIoKtorClientHttpClient.
To Reproduce
My KMP part is using multiple modules that are all build and exported to our Nexus. Meaning on nexus I have my.stuff:module-a:1.0.0 and my.stuff:module-b:1.0.0 which both have an http client that do different things.
Building and uploading to nexus is no issue, but using it within my android application I get the following error
Execution failed for task ':app:checkLongtermStageDebugDuplicateClasses'.
> A failure occurred while executing com.android.build.gradle.internal.tasks.CheckDuplicatesRunnable
Duplicate class org.koin.ksp.generated.KoinDefIoKtorClientHttpClient found in the following modules: module-a-1.0.0-SNAPSHOT.aar -> module-a-1.0.0-SNAPSHOT-runtime (my.stuff:module-a:1.0.0-SNAPSHOT:20241112.085747-4), and module-b-1.0.0-SNAPSHOT.aar -> module-b-1.0.0-SNAPSHOT-runtime (my.stuff:module-b:1.0.0-SNAPSHOT:20241112.085747-4)
Ktor http client is just one example, I am facing this issue with all things that are generated using annotations.
For example also public class KoinDefKotlinxSerializationJsonJson
Describe the bug
Kind of like the same issue as #178 , but I wanted to create a new issue as it may be a little bit different.
I have multiple modules that are all using (for example) Ktor and I build all of them and upload them to Nexus. Once building my Android application it fails with "Duplicate class" for KoinDefIoKtorClientHttpClient.
To Reproduce
My KMP part is using multiple modules that are all build and exported to our Nexus. Meaning on nexus I have my.stuff:module-a:1.0.0 and my.stuff:module-b:1.0.0 which both have an http client that do different things.
Building and uploading to nexus is no issue, but using it within my android application I get the following error
Ktor http client is just one example, I am facing this issue with all things that are generated using annotations.
For example also
public class KoinDefKotlinxSerializationJsonJson
My modules look like this:
&
, so nothing fancy or even special.
My httpClient definition for both modules look kind of like
Making the definitions internal doesn't resolve this problem, I am still facing multiple creations.
Expected behavior
Maybe the package also needs to be applied for third party classes/dependencies?
Koin project used and used version:
Koin Annotation 1.4.0 & 2.0.0-Beta01
The text was updated successfully, but these errors were encountered: