question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Task :react-native-screens:compileDebugKotlin is deprecated. Deprecated in Java

See original GitHub issue

Description

Hello.

i’ve been having these problems for weeks with kotlin daemon sessions and it’s driving me crazy.

Since I started my project (about 2 months ago) every time I need to do a new build this error happens. So I need to delete the .gradle and build files (on android) and after that clean cache to run the app. However, after the last time this happened I couldn’t solve it anymore, making it impossible for me to work for 2 days.

Apparently it’s something related to react navigation dependencies (gesture handler / rnscreens) but I didn’t get an answer about it anywhere.

I’ve already tried to make a new application from scratch and use version 5 of react navigation, but a very similar problem occurs.

The error log is in the Snack or minimal code example

Screenshots

Steps To Reproduce

  1. init a new react native project
  2. Add and configure react navigation dependencies
  3. Try to run

Expected behavior

Build the app

Actual behavior

Task :app:packageDebug FAILED w: Detected multiple Kotlin daemon sessions at build/kotlin/sessions

Deprecated Gradle features were used in this build, making it incompatible with Gradle 8.0.

Reproduction

info Running jetifier to migrate libraries to AndroidX. You can disable it using "--no-jetifier" flag.
Jetifier found 1088 file(s) to forward-jetify. Using 8 workers...
info Starting JS server...
info Installing the app...

> Task :app:processDebugMainManifest
Execution optimizations have been disabled for task ':app:processDebugMainManifest' to ensure correctness due to the following reasons:
  - Gradle detected a problem with the following location: '/home/gabriel/Documentos/app-irriga-global-2.0/android/app/build/intermediates/navigation_json/debug/navigation.json'. Reason: Task ':app:processDebugMainManifest' uses this output of task ':app:copyDebugReactNativeVectorIconFonts' without declaring an explicit or implicit dependency. This can lead to incorrect results being produced, depending on what order the tasks are executed. Please refer to https://docs.gradle.org/7.2/userguide/validation_problems.html#implicit_dependency for more details about this problem.

> Task :app:processDebugManifest
Execution optimizations have been disabled for task ':app:processDebugManifest' to ensure correctness due to the following reasons:
  - Gradle detected a problem with the following location: '/home/gabriel/Documentos/app-irriga-global-2.0/android/app/build/intermediates/compatible_screen_manifest/debug'. Reason: Task ':app:processDebugManifest' uses this output of task ':app:copyDebugReactNativeVectorIconFonts' without declaring an explicit or implicit dependency. This can lead to incorrect results being produced, depending on what order the tasks are executed. Please refer to https://docs.gradle.org/7.2/userguide/validation_problems.html#implicit_dependency for more details about this problem.
  - Gradle detected a problem with the following location: '/home/gabriel/Documentos/app-irriga-global-2.0/android/app/build/intermediates/merged_manifest/debug/AndroidManifest.xml'. Reason: Task ':app:processDebugManifest' uses this output of task ':app:copyDebugReactNativeVectorIconFonts' without declaring an explicit or implicit dependency. This can lead to incorrect results being produced, depending on what order the tasks are executed. Please refer to https://docs.gradle.org/7.2/userguide/validation_problems.html#implicit_dependency for more details about this problem.

> Task :app:processDebugManifestForPackage
Execution optimizations have been disabled for task ':app:processDebugManifestForPackage' to ensure correctness due to the following reasons:
  - Gradle detected a problem with the following location: '/home/gabriel/Documentos/app-irriga-global-2.0/android/app/build/intermediates/merged_manifests/debug'. Reason: Task ':app:processDebugManifestForPackage' uses this output of task ':app:copyDebugReactNativeVectorIconFonts' without declaring an explicit or implicit dependency. This can lead to incorrect results being produced, depending on what order the tasks are executed. Please refer to https://docs.gradle.org/7.2/userguide/validation_problems.html#implicit_dependency for more details about this problem.

> Task :react-native-community_datetimepicker:compileDebugJavaWithJavac

> Task :react-native-community_netinfo:compileDebugJavaWithJavac

> Task :react-native-gesture-handler:compileDebugKotlin
w: Runtime JAR files in the classpath should have the same version. These files were found in the classpath:
    /home/gabriel/.gradle/caches/transforms-3/f0c733c4c094cb9bd1f6b944760c7f9c/transformed/jetified-kotlin-stdlib-jdk8-1.4.10.jar (version 1.4)
    /home/gabriel/.gradle/caches/transforms-3/38305df9788872b121a640eb9f68fa68/transformed/jetified-kotlin-stdlib-jdk7-1.4.10.jar (version 1.4)
    /home/gabriel/.gradle/caches/transforms-3/503676828ac02d04c3acdecae494a224/transformed/jetified-kotlin-stdlib-1.5.20.jar (version 1.5)
    /home/gabriel/.gradle/caches/transforms-3/3b4460c2e3c3f2a825c217e8be53e54d/transformed/jetified-kotlin-stdlib-common-1.5.20.jar (version 1.5)
w: Some runtime JAR files in the classpath have an incompatible version. Consider removing them from the classpath
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-gesture-handler/android/lib/src/main/java/com/swmansion/gesturehandler/FlingGestureHandler.kt: (30, 17): 'constructor Handler()' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-gesture-handler/android/lib/src/main/java/com/swmansion/gesturehandler/GestureHandler.kt: (676, 11): Name shadowed: size
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-gesture-handler/android/lib/src/main/java/com/swmansion/gesturehandler/LongPressGestureHandler.kt: (44, 17): 'constructor Handler()' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-gesture-handler/android/lib/src/main/java/com/swmansion/gesturehandler/TapGestureHandler.kt: (73, 17): 'constructor Handler()' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-gesture-handler/android/lib/src/main/java/com/swmansion/gesturehandler/TapGestureHandler.kt: (82, 17): 'constructor Handler()' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-gesture-handler/android/src/main/java/com/swmansion/gesturehandler/react/RNGestureHandlerEvent.kt: (7, 44): 'RCTEventEmitter' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-gesture-handler/android/src/main/java/com/swmansion/gesturehandler/react/RNGestureHandlerEvent.kt: (17, 11): 'init(Int): Unit' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-gesture-handler/android/src/main/java/com/swmansion/gesturehandler/react/RNGestureHandlerEvent.kt: (33, 42): 'RCTEventEmitter' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-gesture-handler/android/src/main/java/com/swmansion/gesturehandler/react/RNGestureHandlerEvent.kt: (34, 21): 'receiveEvent(Int, String!, WritableMap?): Unit' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-gesture-handler/android/src/main/java/com/swmansion/gesturehandler/react/RNGestureHandlerModule.kt: (439, 30): 'RNGestureHandlerEnabledRootView' is deprecated. Use <GestureHandlerRootView /> component instead. Check gesture handler installation instructions in documentation for more information.
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-gesture-handler/android/src/main/java/com/swmansion/gesturehandler/react/RNGestureHandlerModule.kt: (449, 11): 'onCatalystInstanceDestroy(): Unit' is deprecated. Overrides deprecated member in 'com.facebook.react.bridge.NativeModule'. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-gesture-handler/android/src/main/java/com/swmansion/gesturehandler/react/RNGestureHandlerModule.kt: (454, 33): 'resolveRootTagFromReactTag(Int): Int' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-gesture-handler/android/src/main/java/com/swmansion/gesturehandler/react/RNGestureHandlerModule.kt: (479, 19): 'RNGestureHandlerEnabledRootView' is deprecated. Use <GestureHandlerRootView /> component instead. Check gesture handler installation instructions in documentation for more information.
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-gesture-handler/android/src/main/java/com/swmansion/gesturehandler/react/RNGestureHandlerModule.kt: (505, 33): 'resolveRootTagFromReactTag(Int): Int' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-gesture-handler/android/src/main/java/com/swmansion/gesturehandler/react/RNGestureHandlerModule.kt: (520, 67): Parameter 'motionEvent' is never used
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-gesture-handler/android/src/main/java/com/swmansion/gesturehandler/react/RNGestureHandlerRootHelper.kt: (80, 42): Parameter 'disallowIntercept' is never used
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-gesture-handler/android/src/main/java/com/swmansion/gesturehandler/react/RNGestureHandlerRootHelper.kt: (112, 28): Parameter 'viewTag' is never used
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-gesture-handler/android/src/main/java/com/swmansion/gesturehandler/react/RNGestureHandlerRootView.kt: (54, 23): 'RNGestureHandlerEnabledRootView' is deprecated. Use <GestureHandlerRootView /> component instead. Check gesture handler installation instructions in documentation for more information.
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-gesture-handler/android/src/main/java/com/swmansion/gesturehandler/react/RNGestureHandlerStateChangeEvent.kt: (7, 44): 'RCTEventEmitter' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-gesture-handler/android/src/main/java/com/swmansion/gesturehandler/react/RNGestureHandlerStateChangeEvent.kt: (18, 11): 'init(Int): Unit' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-gesture-handler/android/src/main/java/com/swmansion/gesturehandler/react/RNGestureHandlerStateChangeEvent.kt: (35, 42): 'RCTEventEmitter' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-gesture-handler/android/src/main/java/com/swmansion/gesturehandler/react/RNGestureHandlerStateChangeEvent.kt: (36, 21): 'receiveEvent(Int, String!, WritableMap?): Unit' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-gesture-handler/android/src/main/java/com/swmansion/gesturehandler/react/RNGestureHandlerTouchEvent.kt: (7, 44): 'RCTEventEmitter' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-gesture-handler/android/src/main/java/com/swmansion/gesturehandler/react/RNGestureHandlerTouchEvent.kt: (14, 11): 'init(Int): Unit' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-gesture-handler/android/src/main/java/com/swmansion/gesturehandler/react/RNGestureHandlerTouchEvent.kt: (30, 42): 'RCTEventEmitter' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-gesture-handler/android/src/main/java/com/swmansion/gesturehandler/react/RNGestureHandlerTouchEvent.kt: (31, 21): 'receiveEvent(Int, String!, WritableMap?): Unit' is deprecated. Deprecated in Java

> Task :react-native-safe-area-context:compileDebugJavaWithJavac

> Task :react-native-screens:compileDebugKotlin
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/Screen.kt: (75, 26): 'constructor GuardedRunnable(ReactContext!)' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/ScreenStackFragment.kt: (65, 28): 'setter for targetElevation: Float' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/ScreenStackFragment.kt: (150, 28): 'setter for targetElevation: Float' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/ScreenStackHeaderConfig.kt: (21, 44): 'RCTEventEmitter' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/ScreenStackHeaderConfig.kt: (68, 47): 'RCTEventEmitter' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/ScreenStackHeaderConfig.kt: (69, 15): 'receiveEvent(Int, String!, WritableMap?): Unit' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/ScreenStackHeaderConfig.kt: (163, 56): 'getter for systemWindowInsetTop: Int' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/ScreenStackHeaderConfig.kt: (231, 29): 'setColorFilter(Int, PorterDuff.Mode): Unit' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/ScreenWindowTraits.kt: (56, 22): 'constructor GuardedRunnable(ReactContext!)' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/ScreenWindowTraits.kt: (84, 57): 'getter for systemUiVisibility: Int' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/ScreenWindowTraits.kt: (86, 53): 'SYSTEM_UI_FLAG_LIGHT_STATUS_BAR: Int' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/ScreenWindowTraits.kt: (88, 54): 'SYSTEM_UI_FLAG_LIGHT_STATUS_BAR: Int' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/ScreenWindowTraits.kt: (90, 27): 'setter for systemUiVisibility: Int' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/ScreenWindowTraits.kt: (106, 22): 'constructor GuardedRunnable(ReactContext!)' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/ScreenWindowTraits.kt: (115, 43): 'replaceSystemWindowInsets(Int, Int, Int, Int): WindowInsets' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/ScreenWindowTraits.kt: (116, 47): 'getter for systemWindowInsetLeft: Int' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/ScreenWindowTraits.kt: (118, 47): 'getter for systemWindowInsetRight: Int' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/ScreenWindowTraits.kt: (119, 47): 'getter for systemWindowInsetBottom: Int' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/ScreenWindowTraits.kt: (138, 69): 'FLAG_FULLSCREEN: Int' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/ScreenWindowTraits.kt: (139, 71): 'FLAG_FORCE_NOT_FULLSCREEN: Int' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/ScreenWindowTraits.kt: (141, 69): 'FLAG_FORCE_NOT_FULLSCREEN: Int' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/ScreenWindowTraits.kt: (142, 71): 'FLAG_FULLSCREEN: Int' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/SearchBarView.kt: (9, 44): 'RCTEventEmitter' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/SearchBarView.kt: (117, 47): 'RCTEventEmitter' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/SearchBarView.kt: (118, 15): 'receiveEvent(Int, String!, WritableMap?): Unit' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/events/HeaderBackButtonClickedEvent.kt: (5, 44): 'RCTEventEmitter' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/events/HeaderBackButtonClickedEvent.kt: (7, 51): 'constructor Event<T : Event<(raw) Event<*>>!>(Int)' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/events/HeaderBackButtonClickedEvent.kt: (17, 44): 'RCTEventEmitter' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/events/HeaderBackButtonClickedEvent.kt: (18, 25): 'receiveEvent(Int, String!, WritableMap?): Unit' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/events/ScreenAppearEvent.kt: (5, 44): 'RCTEventEmitter' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/events/ScreenAppearEvent.kt: (7, 40): 'constructor Event<T : Event<(raw) Event<*>>!>(Int)' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/events/ScreenAppearEvent.kt: (13, 44): 'RCTEventEmitter' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/events/ScreenAppearEvent.kt: (14, 25): 'receiveEvent(Int, String!, WritableMap?): Unit' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/events/ScreenDisappearEvent.kt: (5, 44): 'RCTEventEmitter' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/events/ScreenDisappearEvent.kt: (7, 43): 'constructor Event<T : Event<(raw) Event<*>>!>(Int)' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/events/ScreenDisappearEvent.kt: (13, 44): 'RCTEventEmitter' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/events/ScreenDisappearEvent.kt: (14, 25): 'receiveEvent(Int, String!, WritableMap?): Unit' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/events/ScreenDismissedEvent.kt: (5, 44): 'RCTEventEmitter' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/events/ScreenDismissedEvent.kt: (7, 43): 'constructor Event<T : Event<(raw) Event<*>>!>(Int)' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/events/ScreenDismissedEvent.kt: (13, 44): 'RCTEventEmitter' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/events/ScreenDismissedEvent.kt: (17, 25): 'receiveEvent(Int, String!, WritableMap?): Unit' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/events/ScreenTransitionProgressEvent.kt: (5, 44): 'RCTEventEmitter' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/events/ScreenTransitionProgressEvent.kt: (13, 5): 'constructor Event<T : Event<(raw) Event<*>>!>(Int)' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/events/ScreenTransitionProgressEvent.kt: (22, 44): 'RCTEventEmitter' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/events/ScreenTransitionProgressEvent.kt: (27, 25): 'receiveEvent(Int, String!, WritableMap?): Unit' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/events/ScreenWillAppearEvent.kt: (5, 44): 'RCTEventEmitter' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/events/ScreenWillAppearEvent.kt: (7, 44): 'constructor Event<T : Event<(raw) Event<*>>!>(Int)' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/events/ScreenWillAppearEvent.kt: (13, 44): 'RCTEventEmitter' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/events/ScreenWillAppearEvent.kt: (14, 25): 'receiveEvent(Int, String!, WritableMap?): Unit' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/events/ScreenWillDisappearEvent.kt: (5, 44): 'RCTEventEmitter' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/events/ScreenWillDisappearEvent.kt: (7, 47): 'constructor Event<T : Event<(raw) Event<*>>!>(Int)' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/events/ScreenWillDisappearEvent.kt: (13, 44): 'RCTEventEmitter' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/events/ScreenWillDisappearEvent.kt: (14, 25): 'receiveEvent(Int, String!, WritableMap?): Unit' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/events/StackFinishTransitioningEvent.kt: (5, 44): 'RCTEventEmitter' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/events/StackFinishTransitioningEvent.kt: (7, 52): 'constructor Event<T : Event<(raw) Event<*>>!>(Int)' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/events/StackFinishTransitioningEvent.kt: (13, 44): 'RCTEventEmitter' is deprecated. Deprecated in Java
w: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/events/StackFinishTransitioningEvent.kt: (14, 25): 'receiveEvent(Int, String!, WritableMap?): Unit' is deprecated. Deprecated in Java

> Task :react-native-svg:compileDebugJavaWithJavac

> Task :react-native-ui-lib:compileDebugJavaWithJavac

> Task :app:compressDebugAssets
Execution optimizations have been disabled for task ':app:compressDebugAssets' to ensure correctness due to the following reasons:
  - Gradle detected a problem with the following location: '/home/gabriel/Documentos/app-irriga-global-2.0/android/app/build/intermediates/merged_assets/debug/out'. Reason: Task ':app:compressDebugAssets' uses this output of task ':app:copyDebugReactNativeVectorIconFonts' without declaring an explicit or implicit dependency. This can lead to incorrect results being produced, depending on what order the tasks are executed. Please refer to https://docs.gradle.org/7.2/userguide/validation_problems.html#implicit_dependency for more details about this problem.

> Task :realm:compileDebugJavaWithJavac

> Task :app:compileDebugJavaWithJavac

> Task :app:mergeDebugJavaResource
Execution optimizations have been disabled for task ':app:mergeDebugJavaResource' to ensure correctness due to the following reasons:
  - Gradle detected a problem with the following location: '/home/gabriel/Documentos/app-irriga-global-2.0/android/app/build/intermediates/java_res/debug/out'. Reason: Task ':app:mergeDebugJavaResource' uses this output of task ':app:copyDebugReactNativeVectorIconFonts' without declaring an explicit or implicit dependency. This can lead to incorrect results being produced, depending on what order the tasks are executed. Please refer to https://docs.gradle.org/7.2/userguide/validation_problems.html#implicit_dependency for more details about this problem
> Task :app:mergeExtDexDebug
Execution optimizations have been disabled for task ':app:mergeExtDexDebug' to ensure correctness due to the following reasons:
  - Gradle detected a problem with the following location: '/home/gabriel/Documentos/app-irriga-global-2.0/android/app/build/intermediates/duplicate_classes_check/debug'. Reason: Task ':app:mergeExtDexDebug' uses this output of task ':app:copyDebugReactNativeVectorIconFonts' without declaring an explicit or implicit dependency. This can lead to incorrect results being produced, depending on what order the tasks are executed. Please refer to https://docs.gradle.org/7.2/userguide/validation_problems.html#implicit_dependency for more details about this problem.
  - Gradle detected a problem with the following location: '/home/gabriel/Documentos/app-irriga-global-2.0/android/app/build/intermediates/external_file_lib_dex_archives/debug'. Reason: Task ':app:mergeExtDexDebug' uses this output of task ':app:copyDebugReactNativeVectorIconFonts' without declaring an explicit or implicit dependency. This can lead to incorrect results being produced, depending on what order the tasks are executed. Please refer to https://docs.gradle.org/7.2/userguide/validation_problems.html#implicit_dependency for more details about this problem.

> Task :app:mergeLibDexDebug
Execution optimizations have been disabled for task ':app:mergeLibDexDebug' to ensure correctness due to the following reasons:
  - Gradle detected a problem with the following location: '/home/gabriel/Documentos/app-irriga-global-2.0/android/app/build/intermediates/duplicate_classes_check/debug'. Reason: Task ':app:mergeLibDexDebug' uses this output of task ':app:copyDebugReactNativeVectorIconFonts' without declaring an explicit or implicit dependency. This can lead to incorrect results being produced, depending on what order the tasks are executed. Please refer to https://docs.gradle.org/7.2/userguide/validation_problems.html#implicit_dependency for more details about this problem.

> Task :realm:stripDebugDebugSymbols
Unable to strip the following libraries, packaging them as they are: librealm.so.

> Task :app:mergeDebugNativeLibs
Execution optimizations have been disabled for task ':app:mergeDebugNativeLibs' to ensure correctness due to the following reasons:
  - Gradle detected a problem with the following location: '/home/gabriel/Documentos/app-irriga-global-2.0/android/app/build/intermediates/merged_jni_libs/debug/out'. Reason: Task ':app:mergeDebugNativeLibs' uses this output of task ':app:copyDebugReactNativeVectorIconFonts' without declaring an explicit or implicit dependency. This can lead to incorrect results being produced, depending on what order the tasks are executed. Please refer to https://docs.gradle.org/7.2/userguide/validation_problems.html#implicit_dependency for more details about this problem.

> Task :app:stripDebugDebugSymbols
Execution optimizations have been disabled for task ':app:stripDebugDebugSymbols' to ensure correctness due to the following reasons:
  - Gradle detected a problem with the following location: '/home/gabriel/Documentos/app-irriga-global-2.0/android/app/build/intermediates/merged_native_libs/debug/out'. Reason: Task ':app:stripDebugDebugSymbols' uses this output of task ':app:copyDebugReactNativeVectorIconFonts' without declaring an explicit or implicit dependency. This can lead to incorrect results being produced, depending on what order the tasks are executed. Please refer to https://docs.gradle.org/7.2/userguide/validation_problems.html#implicit_dependency for more details about this problem.
Unable to strip the following libraries, packaging them as they are: libbetter.so, libc++_shared.so, libevent-2.1.so, libevent_core-2.1.so, libevent_extra-2.1.so, libfabricjni.so, libfb.so, libfbjni.so, libflipper.so, libfolly_futures.so, libfolly_json.so, libglog.so, libglog_init.so, libhermes-executor-common-debug.so, libhermes-executor-debug.so, libhermes-inspector.so, libhermes.so, libimagepipeline.so, libjsi.so, libjsijniprofiler.so, libjsinspector.so, liblogger.so, libmapbufferjni.so, libnative-filters.so, libnative-imagetranscoder.so, libreact_codegen_rncore.so, libreact_debug.so, libreact_nativemodule_core.so, libreact_render_animations.so, libreact_render_attributedstring.so, libreact_render_componentregistry.so, libreact_render_core.so, libreact_render_debug.so, libreact_render_graphics.so, libreact_render_imagemanager.so, libreact_render_leakchecker.so, libreact_render_mapbuffer.so, libreact_render_mounting.so, libreact_render_runtimescheduler.so, libreact_render_scheduler.so, libreact_render_telemetry.so, libreact_render_templateprocessor.so, libreact_render_textlayoutmanager.so, libreact_render_uimanager.so, libreact_utils.so, libreactconfig.so, libreactnativeblob.so, libreactnativejni.so, libreactnativeutilsjni.so, libreactperfloggerjni.so, librealm.so, libreanimated.so, librrc_image.so, librrc_modal.so, librrc_progressbar.so, librrc_root.so, librrc_scrollview.so, librrc_slider.so, librrc_switch.so, librrc_text.so, librrc_textinput.so, librrc_unimplementedview.so, librrc_view.so, libturbomodulejsijni.so, libyoga.so.

> Task :app:packageDebug FAILED
w: Detected multiple Kotlin daemon sessions at build/kotlin/sessions

Deprecated Gradle features were used in this build, making it incompatible with Gradle 8.0.

You can use '--warning-mode all' to show the individual deprecation warnings and determine if they come from your own scripts or plugins.

See https://docs.gradle.org/7.2/userguide/command_line_interface.html#sec:command_line_warnings

Execution optimizations have been disabled for 9 invalid unit(s) of work during this build to ensure correctness.
Please consult deprecation warnings for more details.
208 actionable tasks: 208 executed
Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
Note: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-svg/android/src/main/java/com/horcrux/svg/VirtualView.java uses or overrides a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
Note: Some input files use unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.
Note: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/realm/react-native/android/src/main/java/io/realm/react/RealmReactPackage.java uses unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.
Note: /home/gabriel/Documentos/app-irriga-global-2.0/android/app/src/debug/java/com/irrigaglobal/ReactNativeFlipper.java uses or overrides a deprecated API.
Note: Recompile with -Xlint:deprecation for details.

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':app:packageDebug'.
> A failure occurred while executing com.android.build.gradle.tasks.PackageAndroidArtifact$IncrementalSplitterRunnable
   > java.lang.OutOfMemoryError (no error message)

* 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 42s

error Failed to install the app. Make sure you have the Android development environment set up: https://reactnative.dev/docs/environment-setup.
Error: Command failed: ./gradlew app:installDebug -PreactNativeDevServerPort=8081
Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
Note: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native-svg/android/src/main/java/com/horcrux/svg/VirtualView.java uses or overrides a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
Note: Some input files use unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.
Note: /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/realm/react-native/android/src/main/java/io/realm/react/RealmReactPackage.java uses unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.
Note: /home/gabriel/Documentos/app-irriga-global-2.0/android/app/src/debug/java/com/irrigaglobal/ReactNativeFlipper.java uses or overrides a deprecated API.
Note: Recompile with -Xlint:deprecation for details.

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':app:packageDebug'.
> A failure occurred while executing com.android.build.gradle.tasks.PackageAndroidArtifact$IncrementalSplitterRunnable
   > java.lang.OutOfMemoryError (no error message)

* 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 42s

    at makeError (/home/gabriel/Documentos/app-irriga-global-2.0/node_modules/execa/index.js:174:9)
    at /home/gabriel/Documentos/app-irriga-global-2.0/node_modules/execa/index.js:278:16
    at processTicksAndRejections (internal/process/task_queues.js:97:5)
    at async runOnAllDevices (/home/gabriel/Documentos/app-irriga-global-2.0/node_modules/@react-native-community/cli-platform-android/build/commands/runAndroid/runOnAllDevices.js:109:5)
    at async Command.handleAction (/home/gabriel/Documentos/app-irriga-global-2.0/node_modules/react-native/node_modules/@react-native-community/cli/build/index.js:192:9)
info Run CLI with --verbose flag for more details.

Platform

  • iOS
  • Android
  • Web
  • Windows
  • tvOS

Workflow

  • Managed workflow
  • [ X ] Bare workflow

Package versions

package version
react-native 0.67.2
@react-navigation/native ^6.0.8
@react-navigation/native-stack ^6.4.0
react-native-screens ^3.10.2
react-native-safe-area-context ^3.3.2
react-native-gesture-handler ^2.1.1
react-native-reanimated ^2.3.1

Issue Analytics

  • State:closed
  • Created a year ago
  • Reactions:7
  • Comments:11 (2 by maintainers)

github_iconTop GitHub Comments

125reactions
gabrielporchercommented, Apr 21, 2022

Hi, Sorry to be away these last few days.

@WoLewicki I can’t share the repository of this project as it is a working project that contains business information, but I’ve been able to resolve this.

@JamesOwen7 Yes, I found a solution.

In my android/build.gradle file i change this:

buildscript {
    ext {
        // ...
        kotlin_version = '1.6.10' // <- add this line
    }

    dependencies {
        // ...
        classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version" // <- add this line
        // ...
    }
}

and I also add increased the memory in android/gradle.properties: org.gradle.jvmargs=-Xmx2048m -XX:MaxMetaspaceSize=512m

With this I was able to run and work again.

Thanks for the help everybody

5reactions
re-aruncommented, Jun 27, 2022

Hi, Sorry to be away these last few days.

@WoLewicki I can’t share the repository of this project as it is a working project that contains business information, but I’ve been able to resolve this.

@JamesOwen7 Yes, I found a solution.

In my android/build.gradle file i change this:

buildscript {
    ext {
        // ...
        kotlin_version = '1.6.10' // <- add this line
    }

    dependencies {
        // ...
        classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version" // <- add this line
        // ...
    }
}

and I also add increased the memory in android/gradle.properties: org.gradle.jvmargs=-Xmx2048m -XX:MaxMetaspaceSize=512m

With this I was able to run and work again.

Thanks for the help everybody

Thanks @gabrielporcher this is working and fixed my issue.

Read more comments on GitHub >

github_iconTop Results From Across the Web

react-native-screens:compileDebugKotlin FAILED
Task :react-native-screens:compileDebugKotlin FAILED Deprecated Gradle features were used in this build, making it incompatible with Gradle ...
Read more >
Event (Camunda Platform Javadocs 7.18.1-ee)
Exposes twitter-like feeds for tasks and process instances. Deprecation This class has been deprecated as of Camunda Platform 7.1. It has been replaced...
Read more >
UnityPlayerActivity.java uses or overrides a deprecated API ...
I just imported facebook sdk to unity for ad campaign for my app. But I get errors when I try to build an...
Read more >
The @Deprecated Annotation in Java - GeeksforGeeks
The @Deprecated annotation tells the compiler that a method, class, or field is deprecated and that it should generate a warning if someone ......
Read more >
Deprecated: Creating an external implementation - IBM
To perform this task, you must be in the IBM® Process Designer desktop editor, which is deprecated. About this task. Using the external...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found