Ask Your Question
0

How can the issue of receiving a duplicate classes error be resolved when including the dependencies of sendbird-live-uikit, sendbird.sdk:uikit, sendbird-calls, and sendbird-android-sdk into one Android project?

asked 2023-07-04 06:03:25 +0000

lakamha gravatar image

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
3

answered 2023-07-04 06:29:02 +0000

lalupa gravatar image

One possible solution to resolve the duplicate classes error when including these dependencies in an Android project is to use the exclude command in the build.gradle file.

For example, you can exclude specific classes or packages from being included in the final build by adding the exclude command to the dependencies section of the file.

Here's an example of how to exclude the duplicate classes between sendbird-live-uikit and sendbird.sdk:uikit dependencies:

dependencies {
    implementation ('com.sendbird.sdk:sendbird-live-uikit:1.0.10') {
        exclude group: 'com.sendbird.sdk', module: 'sendbird-uikit'
    }
    implementation 'com.sendbird.sdk:sendbird-android-sdk:3.0.148'
    implementation 'com.sendbird.sdk:sendbird-calls:1.1.10'
}

This code excludes the sendbird-uikit module from the com.sendbird.sdk:sendbird-live-uikit dependency, so it won't conflict with the sendbird.sdk:uikit dependency.

You can use a similar approach to exclude other modules or libraries that are causing duplicate classes errors.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account. This space is reserved only for answers. If you would like to engage in a discussion, please instead post a comment under the question or an answer that you would like to discuss

Add Answer


Question Tools

Stats

Asked: 2023-07-04 06:03:25 +0000

Seen: 16 times

Last updated: Jul 04 '23