Questions tagged [android-multidex]

Multidex is an Android technology that splits the classes of an Application (and its dependencies) into multiple dex files. (Dex being the format of the classes for the Dalvik/ART VM). Multidex is a workaround the 65 k maximal methods count inside a dex file.

Multidex is an Android technology that splits the classes of an Application (and its dependencies) into multiple dex files. (Dex being the format of the classes for the Dalvik/ART VM). Multidex is a workaround the 65k maximal methods count inside a dex file.

Package Summary

Features

Note that multidex is built-in in Art (Android SDK 5, Lollipop) and is also part of the support libraries

720 questions
3
votes
0 answers

How to reduce dex files in APK

How to reduce dex files to minimal in my project? It has more than 20 dex files Some files only have 1 class, 1 method. ============ Update: For more info, this is my problem about debug apk ============ Update 2: I don't use Instant Run in my…
Long Thanh
  • 41
  • 4
3
votes
1 answer

Multidex enabled - still unable to merge dex

this is my build.gradle android { compileSdkVersion 27 defaultConfig { applicationId "xxxx.xxxx.xxxx" minSdkVersion 21 targetSdkVersion 27 versionCode 1 versionName "1.0" testInstrumentationRunner…
3
votes
0 answers

MutidexKeep file does not work for android espresso apk to declare classes required in the primary DEX file

My test apk has multiple classes.dex . I am trying to get all the classes to appear in the main classes.dex using the multiDexKeepFile and also the multiDexKeepProguard property as mentioned in…
craj
  • 67
  • 1
  • 6
3
votes
2 answers

DexException Multiple dex files define in Android

In my android project am using two JAXB libraries jaxp-ri (for XMLGregorianCalendarImpl class) and jaxb-api(for object to xml conversion). I have added these two libraries in build.gradle file. But when I building my project am getting below…
Sathish
  • 1,481
  • 5
  • 20
  • 33
3
votes
1 answer

Getting app:transformClassesWithDesugarForDebug Exception while compiling project

Gradle build is failing with following app's build.gradle config: android{ compileSdkVersion 26 buildToolsVersion "26.0.2" defaultConfig { applicationId "com.sample.demo" minSdkVersion 21 targetSdkVersion 26 …
gonephishing
  • 1,388
  • 3
  • 18
  • 45
3
votes
0 answers

DexIndexOverflowException with multidex enabled

I searched a lot about this topic, but only found some old answers which tell to enable multidex, which is not relevant for this case. I have this exception during Android Gradle build (task transformDexArchiveWithDexMergerForAppDebug) What went…
marcinm
  • 281
  • 1
  • 2
  • 11
3
votes
1 answer

Android MultiDex app crashing on low APIs on Android Studio 3.0

I was trying to run an app that requires MultiDex using Android Studio 3.0 on an API 16 device and when the app is finally trying to launch, it crashes. The same occurs on other low APIs (eg.: 17, 18, 19) But, when I tried to run the app using the…
Augusto Carmo
  • 4,386
  • 2
  • 28
  • 61
3
votes
1 answer

java.util.MissingResourceException: Can't find bundle for base name javax.servlet.LocalStrings

I have an Android app that uses multidex. It is released and has monthly users in the hundreds of thousands. Every so often I will get ExceptionInInitializerError crashes on Crashlytics. I've never been able to reproduce them. I read that this can…
casolorz
  • 8,486
  • 19
  • 93
  • 200
3
votes
1 answer

Android proguard enabled APK size increases on adding a new library

We have several dependency libraries in our APK and have enabled proguard and multi dex. We have 3 dex files. We intend to keep the APK size as small as possible. We are currently trying to integrate a 'new Ads SDK'. While integrating, we are seeing…
Srikanth
  • 56
  • 6
3
votes
1 answer

Multidex Android Library Module

I have a library module in a gradle project that has connected Android tests, but the test APK references too many methods and needs to be multidexed or ProGuard should be enabled. Is there a way to enable multidex or ProGuard just for the connected…
E.M.
  • 4,498
  • 2
  • 23
  • 30
3
votes
2 answers

Why do I have ClassNotFoundException on my app?

Background Not so long ago, Google has changed the Google Play Console, so that crashes are automatically being reported as soon as they occur, having it as part of what they call "Android Vital". From this day, I got many crash reports that I've…
3
votes
1 answer

ClassNotFoundException extending Android MultiDexApplication class

I'm spending hours to solve this problem, but can't find a solution between the dozens of replies for similar problems. So there's my problem. I'm creating a simple multidex Android app and I need to execute some things at app startup. So, I've…
3
votes
2 answers

gradle project dependency with MultiDex

I have two .aar files that I need to add to my project as dependencies. I imported the projects and did the following and it worked just fine. dependencies { compile project(':zoomcommonlib') compile project(':zoomsdk') } However, I have…
3
votes
0 answers

Verify Error occurring after enabling multidex in devices with android api level less than 21

I am facing a strange scenario where java.lang.VerifyError occurs after enabling multidex. This is happening with any library whose methods are split between the dexes. Any clue why this is happening. Been struck here for long.
swaroop_ps
  • 125
  • 2
  • 4
3
votes
0 answers

DexIndexOverflowException when running androidTests

when running ./gradlew clean connectedWithAnalyticsWithCloudDebugAndroidTest I am getting this error: * What went wrong: Execution failed for task ':android:transformClassesWithDexForWithAnalyticsWithCloudDebug'. >…
ligi
  • 39,001
  • 44
  • 144
  • 244