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

Failed to Compile with Java Project #24

Open
rahat14 opened this issue May 13, 2021 · 8 comments
Open

Failed to Compile with Java Project #24

rahat14 opened this issue May 13, 2021 · 8 comments
Assignees
Labels
question Further information is requested

Comments

@rahat14
Copy link

rahat14 commented May 13, 2021

error msg _> More than one file was found with OS independent path 'META-INF/imagepicker_release.kotlin_module'

@Drjacky
Copy link
Owner

Drjacky commented May 13, 2021

Which version you're using? If v2.1.8, please try v2.1.7 which still use Kotlin 1.4.x.

Also, please try this solution and let me know if it works (whether with the latest version or one before that)

@Drjacky Drjacky self-assigned this May 13, 2021
@Drjacky Drjacky added the question Further information is requested label May 13, 2021
@rahat14
Copy link
Author

rahat14 commented May 17, 2021

Adding This didnot work . used v2.1.8 trying 2.1.7
packagingOptions {
exclude 'META-INF/DEPENDENCIES'
}

@Drjacky
Copy link
Owner

Drjacky commented May 17, 2021

If none of them worked, you could create a sample app and attach it here so, I can check it.

@amankumar367
Copy link

amankumar367 commented Jun 13, 2021

I was also facing a similar type of issue

META-INF/kotlin-stdlib.kotlin_module: Module was compiled with an incompatible version of Kotlin. The binary version of its metadata is 1.5.1, expected version is 1.1.16.

I was having this issue all version v2..1.8...v2.1.11

I tried with v2.1.7 and this working fine

@Drjacky
Copy link
Owner

Drjacky commented Jun 13, 2021

@amankumar367 Please create a sample project and attach it here; I'll check.
Thanks!

@amankumar367
Copy link

amankumar367 commented Jun 13, 2021

It works in the newly created sample project, but facing issues in my existing project.

@Drjacky
Copy link
Owner

Drjacky commented Jun 13, 2021

@rahat14 @amankumar367
You need to add whatever the gradle shows in the error logcat.
For you it'd be something like:

packagingOptions {
exclude 'META-INF/kotlin-stdlib.*'
//Or
exclude 'META-INF/kotlin-stdlib.kotlin_module'
}

Also, let me know what Java and Kotltin versions you have set.
The library uses Kotlin 1.5.10 and Java 1.8

@nirmal700
Copy link

You need to need Kotlin dependency to build.gradle
implementation "androidx.core:core-ktx:1.7.0"
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version
Then Sync the project your project should be okay 👍

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

No branches or pull requests

4 participants