I'm integrating Lottie in my app, I've already done on iOS and it's working very well. But on Android it's not working
I'm getting this error:
AILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':app:transformClassesWithDexBuilderForDevDebug'.
> com.android.build.api.transform.TransformException: com.android.builder.dexing.DexArchiveBuilderException: com.android.builder.dexing.DexArchiveBuilderException: Failed to process /Users/usuario/.gradle/caches/transforms-1/files-1.1/lottie-2.5.6.aar/701ccd4789423b6563831658768ba978/jars/classes.jar
I've followed all steps listed here: http://airbnb.io/lottie/react-native/react-native.html#getting-started and it's not working
Here is how files are:
##### android/build.gradle
buildscript {
repositories {
google()
jcenter()
}
dependencies {
classpath 'com.google.gms:google-services:3.2.0'
classpath 'com.android.tools.build:gradle:3.1.3'
}
}
allprojects {
repositories {
mavenLocal()
google()
jcenter()
maven {
url 'https://maven.google.com'
}
maven {
// All of React Native (JS, Obj-C sources, Android binaries) is installed from npm
url "$rootDir/../node_modules/react-native/android"
}
maven { url "https://jitpack.io" } // used for MPAndroidChart
}
}
rootProject.name = '...'
include ':lottie-react-native'
project(':lottie-react-native').projectDir = new File(rootProject.projectDir, '../node_modules/lottie-react-native/src/android')
...
include ':app'
android {
compileSdkVersion 26
...
}
dependencies {
implementation project(':lottie-react-native') // I've to updated compile to implementation because i'm using firebase
...
}
...
import com.airbnb.android.react.lottie.LottiePackage;
...
@Override
protected List
return Arrays.
new MainReactPackage(),
new LottiePackage(),
...
);
}
.
Does anyone have any idea about what's wrong?
Thanks
Problem solved using this: https://github.com/airbnb/lottie-android/issues/822#issuecomment-401776909
This issue is back again in lottie-RN 2.5.11. Version 2.5.10 is working ok
Yes it is experienced the same on 2.5.11, rolled back package.json to 2.5.10 and linked fine.
REF for searchers: Failed to process lottie-2.5.6.aar
Why is this issue closed ? the problem is indeed in 2.5.11 and wasn't in 2.5.10
Though the solution given in the link works to bypass it
Was this fixed? I'm having this issue right now.
Most helpful comment
This issue is back again in lottie-RN 2.5.11. Version 2.5.10 is working ok