Reputation: 203
Im using react navigation v5.. installed all the dependencies.. now Im getting above error.. FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':react-native-screens:compileDebugJavaWithJavac'.
> java.lang.reflect.UndeclaredThrowableException
* 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
Deprecated Gradle features were used in this build, making it incompatible with Gradle 6.0.
Use '--warning-mode all' to show the individual deprecation warnings.
See https://docs.gradle.org/5.5/userguide/command_line_interface.html#sec:command_line_warnings
Upvotes: 6
Views: 17109
Reputation: 11
it do it when you upgrade your react-native version to 0.69.1 or higher insert the kotlin classpath to build.gradle of app(android\build.gradle) : dependencies { ..... classpath("org.jetbrains.kotlin:kotlin-gradle-plugin:1.5.10") ----- this line ..... // NOTE: Do not place your application dependencies here; they belong // in the individual module build.gradle files }
sorry for my english
Upvotes: 1
Reputation: 91
Run this command in your terminal
// to check if there are any deamon running.
// then restart the server
Upvotes: 9
Reputation: 5502
I think this issue is still open on GitHub issues -> View
If your React Native Version < 0.60 then you can use Jetifier to solve this issue
How to use Jetifier to solve ?
yarn add --dev jetify
"postinstall": "jetify"
If your React Native Version 0.60 > then try this
cd android && ./gradlew clean
Upvotes: 1