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

More than one file was found with OS independent path 'META-INF/library_release.kotlin_module' #134

Closed
AlbertVilaCalvo opened this issue Oct 10, 2019 · 4 comments · Fixed by #146

Comments

@AlbertVilaCalvo
Copy link

Hi, when I add the library to the app/build.gradle file:

debugImplementation "com.github.ChuckerTeam.Chucker:library:3.0.1"
releaseImplementation "com.github.ChuckerTeam.Chucker:library-no-op:3.0.1"

I get the following build error:

Execution failed for task ':app:mergeDebugJavaResource'.
> A failure occurred while executing com.android.build.gradle.internal.tasks.Workers$ActionFacade
   > More than one file was found with OS independent path 'META-INF/library_release.kotlin_module'

Indeed, I have 2 libraries with this file, one of them is chucker:

Captura de Pantalla 2019-10-10 a les 12 58 32

There is a way to fix this with packagingOptions:

packagingOptions {
    exclude 'META-INF/library_release.kotlin_module'
}

However it seems that the root cause can be solved on the library, which is better because it avoids having everyone to add the exclude fix:

Takhion/android-extras-delegates#1
kosi-libs/Kodein#138

Would be nice if this was fixed at the library :)

@AlbertVilaCalvo
Copy link
Author

I've found this related to the error: https://readyset.build/build-failures-kotlin-metadata-errors-f0090cdf948c

@AlbertVilaCalvo
Copy link
Author

I've opened an issue on the other library too: kizitonwose/Calendar#65

@cortinico
Copy link
Member

Thanks for the report @AlbertVilaCalvo
Fix should be #146

@jhamin0511
Copy link

It is work for me.

packagingOptions {
    exclude 'META-INF/library_release.kotlin_module'
}

https://stackoverflow.com/questions/44509608/duplicate-files-copied-in-apk-meta-inf-library-release-kotlin-module

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

Successfully merging a pull request may close this issue.

3 participants