0

Im getting this error when trying to run a react-native up exception in thread main unknown exception anyone to help

5th Apr 2020, 12:14 PM
calvin
calvin - avatar
17 ответов
+ 4
Sorry Gordon, I can't help. I don't use Android Studio
6th Apr 2020, 3:01 PM
Javier Felipe Toribio
Javier Felipe Toribio - avatar
+ 3
Javier Felipe Toribio Thanks for your reply.
6th Apr 2020, 11:39 PM
Gordon
Gordon - avatar
+ 2
Alright, from the error message, you need an Android development environment. Follow the tutorials on this page: https://reactnative.dev/docs/environment-setup Go through the Expo CLI installation process. When testing your app, use a real Android device to scan the QR code to run the app.
5th Apr 2020, 5:02 PM
Gordon
Gordon - avatar
+ 2
Development OS: Windows? Target OS: Android? Have you done step 3 and 4? Configure ANDROID_HOME environment variable Add platform-tools to Path This guy says in Jan 2020 that he has same problem as you, he solved by uninstalling and reinstalling Java https://stackoverflow.com/questions/59728755/command-failed-gradlew-bat-appinstalldebug-preactnativedevserverport-8081 `Turns out I had a problem with my Java. I uninstall JDK and JRE and reinstall the latest version and it worked out for me.` The Java JDK and JRE version must be latest.
6th Apr 2020, 8:47 AM
Gordon
Gordon - avatar
+ 2
Not sure, havn't installed Java IDE on my computer. Danijel Ivanović, do you know about JRE version?
6th Apr 2020, 12:30 PM
Gordon
Gordon - avatar
+ 2
calvin Don't worry, a Java expert will come up. Just in case Danijel is busy, let me find one more Java expert I know. Javier Felipe Toribio Is there something you can share with us, regarding JRE version, especially for Android Studio?
6th Apr 2020, 2:29 PM
Gordon
Gordon - avatar
+ 1
What's the exception?
5th Apr 2020, 12:17 PM
Gordon
Gordon - avatar
+ 1
Why is Gradle involved? Which tutorial are you following? Can you give me a link to examine?
6th Apr 2020, 1:28 AM
Gordon
Gordon - avatar
+ 1
Have your been solved?
6th Apr 2020, 9:05 AM
Gordon
Gordon - avatar
+ 1
Danijel Ivanović must have missed my tag yesterday Hello Danijel, have you used ReactNative with ReactNative CLI? Any chance you can help this asker? Gordon Sorry my friend, I didn't work with. calvin Maybe here you can find something useful : • https://reactnative.dev/docs/0.5/getting-started
7th Apr 2020, 2:37 PM
Gordon
Gordon - avatar
0
How do I post an image here
5th Apr 2020, 12:40 PM
calvin
calvin - avatar
0
Here is the error: Error failed to install the app. Make sure you have the Android development environment set up: https://reactnative Dev/docs/getting-started.html#android-development-environment. run cli with --verbose flag for more details. Error command failed: gradlew.bat app: installDebug-preactnativedevserverport=8081 Exception in thread "main" java.net.connectexception: connection timed out: connect
5th Apr 2020, 12:48 PM
calvin
calvin - avatar
0
Yah I know that I was trying to use react-native with Android studio because expo has some limitations and I did go through the tutorials on the page and did everything that was asked but it's still giving me an error I think it's something to do with gradle
5th Apr 2020, 6:05 PM
calvin
calvin - avatar
0
https://reactnative.dev/docs/environment-setup then you go to react-native cli quickstart
6th Apr 2020, 7:44 AM
calvin
calvin - avatar
0
Ok thanks
6th Apr 2020, 9:02 AM
calvin
calvin - avatar
0
I already have Java 14 installed maybe the problem is the jre but don't they come as a package?
6th Apr 2020, 10:56 AM
calvin
calvin - avatar
0
When I googled it it seems Java and jre version are the same
6th Apr 2020, 1:02 PM
calvin
calvin - avatar