简体   繁体   English

配置项目“:app”时出现问题。 在 react-native 中并给出一些字节码作为错误

[英]A problem occurred configuring project ':app'. in react-native and give some byte code as an error

After creating the project when i run the react-native app,在我运行 react-native 应用程序时创建项目后,

it gives me this error.它给了我这个错误。

FAILURE: Build failed with an exception.

* What went wrong:

A problem occurred configuring project ':app'.

> Failed to notify project evaluation listener.
> Uninitialized object exists on backward branch 142
 Exception Details:
   Location:
     com/android/build/gradle/internal/pipeline/VariantInfoImpl.<init>(Lcom/android/build/gradle/internal/scope/VariantScope;)V @200: goto
   Reason:
     Error exists in the bytecode
   Bytecode:
     0x0000000: 2b12 3cb8 0034 2a2b b900 4201 0059 1244
     0x0000010: b800 47b6 004d b900 5201 002b b900 5401
     0x0000020: 0059 1256 b800 472b b900 4201 0059 1244
     0x0000030: b800 47b6 005a c000 5c59 125e b800 47b9
     0x0000040: 0061 0100 5912 63b8 0047 2bb9 0042 0100
     0x0000050: 5912 44b8 0047 b600 6759 1269 b800 47c0
     0x0000060: 006b 4d3a 0e3a 0d36 0c3a 0b03 3e2c 3a04
     0x0000070: bb00 6d59 2c10 0ab8 0073 b700 76c0 0078
     0x0000080: 3a05 0336 0619 04b9 007c 0100 3a07 1907
     0x0000090: b900 8101 0099 0036 1907 b900 8501 003a
     0x00000a0: 0819 0519 08c0 0087 3a09 3a0f 0336 0a19
     0x00000b0: 0959 1289 b800 47b9 008a 0100 3a10 190f
     0x00000c0: 1910 b900 8e02 0057 a7ff c619 05c0 0090
     0x00000d0: 3a0f 190b 150c 190d 190e 190f c000 6bb8
     0x00000e0: 0096 2bb9 0042 0100 5912 44b8 0047 b600
     0x00000f0: 5ac0 005c 5912 5eb8 0047 b900 9801 00b7
     0x0000100: 009a b1
   Stackmap Table:
     full_frame(@142,
{UninitializedThis,Object[#62],Object[#107],Integer,
Object[#107],Object[#120],Integer,Object[#126],Top,Top,Top,
UninitializedThis,Integer,Object[#169],Object[#same_frame(@203)


* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --
debug option to get more log output. Run with --scan to get full insights.

* Get more help at https://help.gradle.org

BUILD FAILED in 8s

error Failed to install the app. Make sure you have the Android development 
environment set up: https://facebook.github.io/react-native/docs/getting-
started.html#android-development-environment. Run CLI with --verbose flag 
for more details.

Error: Command failed: gradlew.bat app:installDebug -
PreactNativeDevServerPort=8081

I have changed the我已经改变了

classpath("com.android.tools.build:gradle:3.4.1") to 3.4.2 classpath("com.android.tools.build:gradle:3.4.1") 到 3.4.2

It didn't work.它没有用。 i can't understand the problem.我无法理解这个问题。 Need support.需要支持。 I have re-installed the modules but it gives the same issue.我已经重新安装了模块,但它给出了同样的问题。

Below is my path variable...下面是我的路径变量...

环境变量

System variables系统变量

系统变量

By Changing The SDK version, I have fixed my issue... and some other have suggested the same thing.通过更改 SDK 版本,我解决了我的问题……其他一些人也提出了同样的问题。

My jdk1.8.0_20 was not working.我的 jdk1.8.0_20 不工作。 So i have just changed the jdk to jdk-12.0.2.所以我刚刚将jdk更改为jdk-12.0.2。 I don't know if it is correct or not.我不知道它是否正确。

This question is related to some other question but i could not find it then...这个问题与其他一些问题有关,但我当时找不到它...

  1. Scala build crashed Scala 构建崩溃

Problem was in minor JDK version.问题出在次要 JDK 版本中。 Scala 2.12 require's newer version of JDK then 1.8.0_111. Scala 2.12 需要较新版本的 JDK,然后是 1.8.0_111。 So after JDK upgrade everything work.所以在JDK升级后一切正常。

i wish it might help some.我希望它可以帮助一些人。

Thanks.谢谢。

您可以尝试使用 npx @react-native-community/cli doctor 来获取确切的问题,这样您就可以轻松解决它

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 React native 集成应用程序expo配置错误配置项目&#39;:expo&#39;时出现问题 - React native integrated app expo configuration error A problem occurred configuring project ':expo' 在 React Native 中配置项目时出现问题 - A problem occurred configuring project in React Native 运行反应原生裸项目导致错误配置项目':react-native-reanimated'时出现问题 - Running react native bare project results in error A problem occurred configuring project ':react-native-reanimated' 配置项目“:react-native-gesture-handler”时出现问题 - A problem occurred configuring project ':react-native-gesture-handler' 配置项目&#39;:react-native-vector-icons&#39;时发生问题 - A problem occurred configuring project ':react-native-vector-icons' 配置项目 ':@volst_react-native-tuya' 时出现问题 - A problem occurred configuring project ':@volst_react-native-tuya' 配置项目react-native-photo-view时发生错误 - error occurred configuring project react-native-photo-view 构建失败“配置项目时出现问题:react-native-reanimated”。 在 React Native 项目中 - Build failed 'A problem occurred configuring project ':react-native-reanimated'. in React native project Flutter:gradle 构建失败,错误为“评估根项目 &#39;android&#39; 时出现问题 &gt; 配置项目 &#39;:app&#39; 时出现问题。” - Flutter:gradle build failed with error "A problem occurred evaluating root project 'android' > A problem occurred configuring project ':app'." React Native Android 构建失败 - 配置项目“:expo-image-loader”时出现问题。java.lang.IllegalArgumentException(无错误消息) - React Native Android Build Failure - A problem occurred configuring project ':expo-image-loader'.java.lang.IllegalArgumentException (no error message)
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM