Duplicate files copied in APK - sep_approx_spanish.txt

397 views
Skip to first unread message

Aubrey Malabie

unread,
Oct 8, 2016, 10:56:01 AM10/8/16
to Google App Engine
Hi,

I'm trying to use GAE from Android Studio 2.2 and I'm running into this error: I've rebuilt the project with no errors but the crash happens when I try to run the app. Apparently, sep_approx_spanish.txt appears in the two gae jars as shown in the error below. How do I resolve this?

I've tried this in the app's build.gradle file:
packagingOptions {
exclude 'META-INF/DEPENDENCIES.txt'
exclude 'META-INF/LICENSE.txt'
exclude 'META-INF/NOTICE.txt'
exclude 'META-INF/ASL2.0'
exclude 'META-INF/NOTICE'
exclude 'META-INF/LICENSE'
exclude 'META-INF/maven'
exclude 'META-INF/com/google/appengine/repackaged/org/apache/commons/codec/language/bm/sep_approx_spanish.txt'
}

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':testapp:transformResourcesWithMergeJavaResForDebug'.
> com.android.build.api.transform.TransformException: com.android.builder.packaging.DuplicateFileException: Duplicate files copied in APK com/google/appengine/repackaged/org/apache/commons/codec/language/bm/sep_approx_spanish.txt
  File1: /Users/aubreymalabie/.gradle/caches/modules-2/files-2.1/com.google.appengine/appengine-endpoints/1.9.42/5c25efed254f8f9846d04b156e68283055efd320/appengine-endpoints-1.9.42.jar
  File2: /Users/aubreymalabie/.gradle/caches/modules-2/files-2.1/com.google.appengine/appengine-api-1.0-sdk/1.9.42/c972bc847992e5512eb4338a38cc2392e56760f6/appengine-api-1.0-sdk-1.9.42.jar

Nick (Cloud Platform Support)

unread,
Oct 13, 2016, 6:16:34 PM10/13/16
to Google App Engine
Hey Aubrey,

This problem appears to be a specific technical issue. Something like this should be posted to Stack Overflow rather than this forum, which is meant for more high-level discussion and general design patterns on the platform and services. 

Nonetheless I'm happy to help assist until the point comes that this can be posted as a clear question to Stack Overflow which would allow a user to work on it. I think some pieces of information missing that would be useful would be:

  • The directory structure
  • The relevant portions of the build file
  • The results of testing solutions to issues of this kind which appear elsewhere on the web
Let me know if you have any questions or any additional relevant information. I'm here to help!

Cheers,

Nick
Cloud Platform Community Support
Reply all
Reply to author
Forward
0 new messages