-
Notifications
You must be signed in to change notification settings - Fork 77
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
[Android] Nothing works. Duplicate class #274
Comments
For the first task: Ensure that your app is using compatible versions of the dependencies required by the io.libp2p:jvm-libp2p-minimal library. Check the library's documentation to find out which dependencies are required and their version numbers. For the second: Try |
@HarshPanchal18 This error occurs on an empty project. In other words, the library doesn't work |
Yes I know but this is about Gradle Configs. I also faced the same often at starting. I solved by implementing the dependencies with compatible version. |
@HarshPanchal18 What dependencies did you add to make it disappear? |
I'd been tried to downgrade the val kotlin_version by extra("1.6.10")
dependencies {
classpath("org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version")
} |
@HarshPanchal18 No. It doesn't help. The library doesn't work. |
It seems I'm the only one in the world who wants to run libp2p on Android. |
It would be better if you talked to the developer of this for a more clarified answer. |
@HarshPanchal18 As you can see I'm here and I'm trying to talk to a developer. He's not answering. |
@master255 Try to mention him/her. |
@Nashatyrev @jezhiggins @shahankhatch @ajsutton @protocol @jtraglia @ianopolous Someone tell me how to use this library in Android? |
@HarshPanchal18 It looks like the project is dead, and so are the developers. Or it's secret information. |
@master255 you might want to check this PR #275 branch. |
@Nashatyrev I checked. These errors occur on an empty, new project. This branch I do not know how to test, because the project does not compile. |
My Android Studio version: Android Studio Flamingo | 2022.2.1 Patch 1 and nothing works. |
@Nashatyrev After compiling I get a file like this. Which gives me an error when I create the Host. |
@master255 sorry, didn't get the original case you were complaining about. Here are modifications I've come up with to compile Android project:
dependencyResolutionManagement {
repositories {
// ....
maven { url "https://dl.cloudsmith.io/public/libp2p/jvm-libp2p/maven/" }
maven { url "https://artifacts.consensys.net/public/maven/maven/" }
}
}
dependencies {
// ....
implementation('io.libp2p:jvm-libp2p-minimal:0.10.0-RELEASE') {
exclude group: 'io.netty', module: 'netty-transport-native-epoll'
exclude group: 'io.netty', module: 'netty-transport-native-kqueue'
exclude group: 'io.netty', module: 'netty-resolver-dns-native-macos'
}
// ....
}
android {
// ...
packagingOptions {
resources {
// ...
excludes += 'META-INF/INDEX.LIST'
excludes += 'META-INF/DEPENDENCIES'
excludes += 'META-INF/io.netty.versions.properties'
}
}
} |
@Nashatyrev Now another error:
|
Okay. I was able to start the project. This required me to raise the minimum api to 26. |
When executed:
I get this error:
|
@Nashatyrev And is there even one example of how the library works? Nothing works. No pinger, no chatter... just a dead library. |
Another error when running an empty application with these parameters:
|
Ok. No one said and nowhere is it written that I need to compile the go-libp2p library itself and add it to the project. Is this true? I was able to create a chat and send a message. |
The library (implementation 'io.libp2p:jvm-libp2p-minimal:0.10.0-RELEASE') does not compile in Android Studio. There are a lot of errors:
FAILURE: Build completed with 2 failures.
1: Task failed with an exception.
Execution failed for task ':app:checkDebugDuplicateClasses'.
Execution failed for task ':app:mergeDebugJavaResource'.
The text was updated successfully, but these errors were encountered: