I can confirm that it works now after upgrading of exp cli to 45.1.0
mine is still failing , same error but i have detached my project from expo
My build is failing as well. Canât run exp build
because my project is detached.
[exp] exp build is not supported for detached projects.
I can confirm that it works after adding the following to build.gradle
to a detached build.
dependencies {
compile 'com.parse.bolts:bolts-android:1.1.3'
}
I added this snippet posted by @rintoj â
dependencies {
compile 'com.parse.bolts:bolts-android:1.1.3'
}
This allows our app to be assembled in debug mode, but now our release build fails with this error:
:app:mergeMainReleaseAssets
> Building 95%
> :app:transformClassesWithJarMergingForMainRelease:app:transformClassesWithJarMergingForMainRelease FAILED
> Building 95%
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':app:transformClassesWithJarMergingForMainRelease'.
> com.android.build.api.transform.TransformException: java.util.zip.ZipException: duplicate entry: bolts/AggregateException.class
@jesse You mentioned âthis should be fixedâ â would you mind sharing the root cause of the issue?
You need to remove the exclude module
block from compile 'com.facebook.android:facebook-android-sdk:4.+'
Now!!
$ create-react-native-app sample
$ cd sample
$ yarn run eject
$ cd android
$ ./gradlew assembleDebug
and Deploy â bolts.AppLinks Error!!
When will it be fixed?
PleaseâŚ
@jesse
Hi I had same problem and seems to fix it after applying your example.
But now I am facing another error message.
Do you have any idea?
this kind of error is really frustrating.
@jesse
Please give us the guild for detached project too!
Iâve found above solution in stackoverflow. This seems like what expo should do for me since facebok sdk project should be in there already.
@jesse @pandeiro
Can you please help me with this? Android is never running ⌠in detached expo app.
Jesse said comment out the exclude, you commented out the entire compile block. Try just commenting out the line that begins with âexcludeâ like so:
compile (âcom.facebook.android:facebook-android-sdk:4.+â) {
// exclude module: âbolts-androidâ
}
I was having same issue, this seemed to solve for me.
Sorry again about this issue. Will be patched in the next release (tomorrow or friday)
Is there any update on this, have been on hold for 3 days. Wasted all my day today to fix this myself before knowing this was an expo issue
Edit: After creating a new project from scratch and moving my code there, then ejecting, It was working fine.
Tested just now:
- create-react-native-app test
- cd test
- yarn run eject (select ExpoKit)
- exp start
- Run app from Android studio
11-20 09:40:01.906 16104-16104/? E/AndroidRuntime: FATAL EXCEPTION: main
Process: xxx.yyy.zzz, PID: 16104
java.lang.NoClassDefFoundError: Failed resolution of: Lbolts/AppLinks;
Commenting out the exclude from build.gradle doesnât help.
NoClassDefFoundError in Java comes when Java Virtual Machine is not able to find a particular class at runtime which was available at compile time. After you compile your code, you end up with .class files for each class in your program. These binary files are the bytecode that Java interprets to execute your program. The NoClassDefFoundError indicates that the classloader (in this case java.net.URLClassLoader), which is responsible for dynamically loading classes, cannot find the .class file for the class that youâre trying to use.
NoClassDefFoundError can occur for multiple reasons like
-
ClassNotFoundException â .class not found for that referenced class irrespective of whether it is available at compile time or not(i.e base/child class).
-
Class file located, but Exception raised while initializing static variables
-
Class file located, Exception raised while initializing static blocks