Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Task :react-native-gesture-handler:compileDebugKotlin FAILED #2427

Closed
inmess opened this issue Feb 28, 2023 · 38 comments
Closed

Task :react-native-gesture-handler:compileDebugKotlin FAILED #2427

inmess opened this issue Feb 28, 2023 · 38 comments
Labels
Missing info Platform: Android This issue is specific to Android Repro provided A reproduction with a snack or repo is provided

Comments

@inmess
Copy link

inmess commented Feb 28, 2023

Description

image
image

Dependencies:

  "dependencies": {
    "expo": "~47.0.12",
    "expo-status-bar": "~1.4.2",
    "react": "18.1.0",
    "react-native": "0.70.5",
    "react-native-gesture-handler": "^2.9.0",
    "react-native-reanimated": "^2.14.4",
    "expo-splash-screen": "~0.17.5"
  },
  "devDependencies": {
    "@babel/core": "^7.20.0"
  },

run in MacOS, m1

Steps to reproduce

What I've done:

  1. create a new project and run expo prebuild

  2. Install those dependencies(RNGH, react-native-reanimated) with yarn add

  3. Enable new arch by adding "jsEngine": "hermes" to app.json,

  4. In gradle.properties I changed:
    newArchEnabled=true and expo.jsEngine=hermes

  5. In android/app/build.gradle:
    def enableHermes = project.ext.react.get("enableHermes", true);

  6. Then I run cd android/ && ./gradlew clean

  7. While I run npx expo run:android, errors occurred as in the screenshots.

Snack or a link to a repository

https://github.com/inmess/rngh-bug-repo.git

Gesture Handler version

2.9.0

React Native version

0.70.5

Platforms

Android

JavaScript runtime

Hermes

Workflow

Expo bare workflow

Architecture

Fabric (New Architecture)

Build type

Debug mode

Device

Real device

Device model

No response

Acknowledgements

Yes

@github-actions github-actions bot added Platform: Android This issue is specific to Android Missing info labels Feb 28, 2023
@github-actions
Copy link

github-actions bot commented Feb 28, 2023

Hey! 👋

It looks like you've omitted a few important sections from the issue template.

Please complete Steps to reproduce section.

@github-actions github-actions bot added the Repro provided A reproduction with a snack or repo is provided label Feb 28, 2023
@inmess
Copy link
Author

inmess commented Feb 28, 2023

More Information of error

FAILURE: Build completed with 3 failures.

1: Task failed with an exception.
-----------
* What went wrong:
Execution failed for task ':react-native-gesture-handler:configureCMakeDebug[arm64-v8a]'.
> [CXX1405] error when building with cmake using /Volumes/T7/Documents/test-app/node_modules/react-native-gesture-handler/android/src/main/jni/CMakeLists.txt: Build command failed.
  Error while executing process /Users/gabrielcheng/Library/Android/sdk/cmake/3.18.1/bin/cmake with arguments {-H/Volumes/T7/Documents/test-app/node_modules/react-native-gesture-handler/android/src/main/jni -DCMAKE_SYSTEM_NAME=Android -DCMAKE_EXPORT_COMPILE_COMMANDS=ON -DCMAKE_SYSTEM_VERSION=21 -DANDROID_PLATFORM=android-21 -DANDROID_ABI=arm64-v8a -DCMAKE_ANDROID_ARCH_ABI=arm64-v8a -DANDROID_NDK=/Users/gabrielcheng/Library/Android/sdk/ndk/21.4.7075529 -DCMAKE_ANDROID_NDK=/Users/gabrielcheng/Library/Android/sdk/ndk/21.4.7075529 -DCMAKE_TOOLCHAIN_FILE=/Users/gabrielcheng/Library/Android/sdk/ndk/21.4.7075529/build/cmake/android.toolchain.cmake -DCMAKE_MAKE_PROGRAM=/Users/gabrielcheng/Library/Android/sdk/cmake/3.18.1/bin/ninja -DCMAKE_CXX_FLAGS=-O2 -frtti -fexceptions -Wall -Werror -std=c++17 -DCMAKE_LIBRARY_OUTPUT_DIRECTORY=/Volumes/T7/Documents/test-app/node_modules/react-native-gesture-handler/android/build/intermediates/cxx/Debug/1s575c3k/obj/arm64-v8a -DCMAKE_RUNTIME_OUTPUT_DIRECTORY=/Volumes/T7/Documents/test-app/node_modules/react-native-gesture-handler/android/build/intermediates/cxx/Debug/1s575c3k/obj/arm64-v8a -DCMAKE_BUILD_TYPE=Debug -B/Volumes/T7/Documents/test-app/node_modules/react-native-gesture-handler/android/.cxx/Debug/1s575c3k/arm64-v8a -GNinja -DAPP_BUILD_DIR=/Volumes/T7/Documents/test-app/android/app/build -DREACT_NATIVE_DIR=/Volumes/T7/Documents/test-app/node_modules/react-native -DANDROID_STL=c++_shared}
  -- Detecting C compiler ABI info
  -- Detecting C compiler ABI info - done
  -- Check for working C compiler: /Users/gabrielcheng/Library/Android/sdk/ndk/21.4.7075529/toolchains/llvm/prebuilt/darwin-x86_64/bin/clang - skipped
  -- Detecting C compile features
  -- Detecting C compile features - done
  -- Detecting CXX compiler ABI info
  -- Detecting CXX compiler ABI info - done
  -- Check for working CXX compiler: /Users/gabrielcheng/Library/Android/sdk/ndk/21.4.7075529/toolchains/llvm/prebuilt/darwin-x86_64/bin/clang++ - skipped
  -- Detecting CXX compile features
  -- Detecting CXX compile features - done
  -- Configuring incomplete, errors occurred!
  See also "/Volumes/T7/Documents/test-app/node_modules/react-native-gesture-handler/android/.cxx/Debug/1s575c3k/arm64-v8a/CMakeFiles/CMakeOutput.log".

  CMake Error at CMakeLists.txt:9 (include):
    include could not find load file:

      /Volumes/T7/Documents/test-app/node_modules/react-native/ReactAndroid/cmake-utils/folly-flags.cmake


  CMake Error at CMakeLists.txt:17 (find_package):
    Could not find a package configuration file provided by "ReactAndroid" with
    any of the following names:

      ReactAndroidConfig.cmake
      reactandroid-config.cmake

    Add the installation prefix of "ReactAndroid" to CMAKE_PREFIX_PATH or set
    "ReactAndroid_DIR" to a directory containing one of the above files.  If
    "ReactAndroid" provides a separate development package or SDK, be sure it
    has been installed.

@student513
Copy link

same issue

@devgunatwork
Copy link

devgunatwork commented Mar 16, 2023

same issue with RN version 0.71.4

@cisiwen
Copy link

cisiwen commented Mar 22, 2023

Similar issue but slight different

'boost/mpl/count.hpp' file not found

`FAILURE: Build completed with 2 failures.

1: Task failed with an exception.

  • What went wrong:
    Execution failed for task ':react-native-gesture-handler:buildCMakeDebug[arm64-v8a]'.

com.android.ide.common.process.ProcessException: ninja: Entering directory `/Users/xxxxxxxxxxx/Documents/project/xxxxxx/xxxxxx.xxxxxxxxx/node_modules/react-native-gesture-handler/android/.cxx/Debug/w6d2y2f2/arm64-v8a'
[1/2] Building CXX object CMakeFiles/gesturehandler.dir/cpp-adapter.cpp.o
FAILED: CMakeFiles/gesturehandler.dir/cpp-adapter.cpp.o
/Users/xxxxxxxxxxx/Library/Android/sdk/ndk/23.1.7779620/toolchains/llvm/prebuilt/darwin-x86_64/bin/clang++ --target=aarch64-none-linux-android24 --sysroot=/Users/xxxxxxxxxxx/Library/Android/sdk/ndk/23.1.7779620/toolchains/llvm/prebuilt/darwin-x86_64/sysroot -Dgesturehandler_EXPORTS -isystem /Users/xxxxxxxxxxx/.gradle/caches/transforms-3/a907c5f55cb4cb0ae8ad3aa0f22077df/transformed/jetified-react-android-0.71.4-debug/prefab/modules/react_render_core/include -isystem /Users/xxxxxxxxxxx/.gradle/caches/transforms-3/a907c5f55cb4cb0ae8ad3aa0f22077df/transformed/jetified-react-android-0.71.4-debug/prefab/modules/react_render_uimanager/include -isystem /Users/xxxxxxxxxxx/.gradle/caches/transforms-3/a907c5f55cb4cb0ae8ad3aa0f22077df/transformed/jetified-react-android-0.71.4-debug/prefab/modules/jsi/include -isystem /Users/xxxxxxxxxxx/.gradle/caches/transforms-3/a907c5f55cb4cb0ae8ad3aa0f22077df/transformed/jetified-react-android-0.71.4-debug/prefab/modules/react_nativemodule_core/include -O2 -frtti -fexceptions -Wall -Werror -std=c++17 -g -fno-limit-debug-info -fPIC -DFOLLY_NO_CONFIG=1 -DFOLLY_HAVE_CLOCK_GETTIME=1 -DFOLLY_USE_LIBCPP=1 -DFOLLY_MOBILE=1 -DFOLLY_HAVE_RECVMMSG=1 -DFOLLY_HAVE_PTHREAD=1 -DFOLLY_HAVE_XSI_STRERROR_R=1 -MD -MT CMakeFiles/gesturehandler.dir/cpp-adapter.cpp.o -MF CMakeFiles/gesturehandler.dir/cpp-adapter.cpp.o.d -o CMakeFiles/gesturehandler.dir/cpp-adapter.cpp.o -c /Users/xxxxxxxxxxx/Documents/project/xxxxxx/xxxxxx.xxxxxxxxx/node_modules/react-native-gesture-handler/android/src/main/jni/cpp-adapter.cpp
In file included from /Users/xxxxxxxxxxx/Documents/project/xxxxxx/xxxxxx.xxxxxxxxx/node_modules/react-native-gesture-handler/android/src/main/jni/cpp-adapter.cpp:4:
In file included from /Users/xxxxxxxxxxx/.gradle/caches/transforms-3/a907c5f55cb4cb0ae8ad3aa0f22077df/transformed/jetified-react-android-0.71.4-debug/prefab/modules/react_render_uimanager/include/react/renderer/uimanager/primitives.h:15:
In file included from /Users/xxxxxxxxxxx/.gradle/caches/transforms-3/a907c5f55cb4cb0ae8ad3aa0f22077df/transformed/jetified-react-android-0.71.4-debug/prefab/modules/react_render_core/include/react/renderer/core/ShadowNode.h:14:
In file included from /Users/xxxxxxxxxxx/.gradle/caches/transforms-3/a907c5f55cb4cb0ae8ad3aa0f22077df/transformed/jetified-react-android-0.71.4-debug/prefab/modules/react_nativemodule_core/include/butter/small_vector.h:15:
/Users/xxxxxxxxxxx/.gradle/caches/transforms-3/a907c5f55cb4cb0ae8ad3aa0f22077df/transformed/jetified-react-android-0.71.4-debug/prefab/modules/react_nativemodule_core/include/folly/small_vector.h:35:10: fatal error: 'boost/mpl/count.hpp' file not found
#include <boost/mpl/count.hpp>
^~~~~~~~~~~~~~~~~~~~~
1 error generated.
ninja: build stopped: subcommand failed.

C++ build system [build] failed while executing:
/Users/xxxxxxxxxxx/Library/Android/sdk/cmake/3.22.1/bin/ninja
-C
/Users/xxxxxxxxxxx/Documents/project/xxxxxx/xxxxxx.xxxxxxxxx/node_modules/react-native-gesture-handler/android/.cxx/Debug/w6d2y2f2/arm64-v8a
gesturehandler
from /Users/xxxxxxxxxxx/Documents/project/xxxxxx/xxxxxx.xxxxxxxxx/node_modules/react-native-gesture-handler/android

  • 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.
==============================================================================

2: Task failed with an exception.

  • What went wrong:
    java.lang.StackOverflowError (no error message)`

@cisiwen
Copy link

cisiwen commented Mar 22, 2023

Just download the gesture handler git and build the FabricExample work fine
first the problem happened when newArchEnabled=true
if i change from react native version 0.71.4 to 0.71.0 my project compile properly

@NSShentu
Copy link

Same issue here with RN 0.71.3 and RNGH 2.9.0
.gradle/caches/transforms-3/3b4066e6a8ae874968e4742fedafe30a/transformed/jetified-react-android-0.71.3-debug/prefab/modules/react_nativemodule_core/include/folly/small_vector.h:35:10: fatal error: 'boost/mpl/count.hpp' file not found

@AliMSbaee
Copy link

Same issue:
fatal error: 'boost/mpl/count.hpp' file not found
RN@0.71.0
RNGH@2.9.0

@achorein
Copy link

same problem here (expo 48, RN 0.71.4, newArch, reanimated3), maybe related to something like expo/expo#20679

@natehurley
Copy link

natehurley commented Mar 29, 2023

Same issue:
fatal error: 'boost/mpl/count.hpp' file not found

Versions:
React Native @ 0.71.5 (Nothing changes when I downgraded React Native to 0.71.0)
RN Gesture Handler @ 2.9.0
Reanimated @ 3.0.2

Enviroment:
MacBook Pro M1 Pro @ 13.2.1

Would love to hear any potential solutions anyone has come up with... I can't seem to find any info regarding this issue specifically anywhere online, sadly.

@Makar8000
Copy link

Makar8000 commented Mar 30, 2023

Getting the same issue with the following versions:
React Native: 0.71.5
react-native-gesture-handler: 2.9.0

The error:
Execution failed for task ':react-native-gesture-handler:configureCMakeRelWithDebInfo[arm64-v8a]'.

@beeboopx
Copy link

beeboopx commented Apr 7, 2023

Same Android build issue: fatal error: 'boost/mpl/count.hpp' file not found

RN: 0.71.3 w/ new architecture
react-native-gesture-handler: 2.9.0
react-native-reanimated: 3.0.2
Gradle Wrapper: 7.5.1
Android Gradle Plugin: 7.4.1

Update:

Upgraded RN to 0.71.6
Downgraded Android Gradle Plugin: 7.3.1 (downgraded due to experiencing another issue with AGP 7.4.1 https://issuetracker.google.com/issues/232060576)

Not sure if it was the AGP downgrade or RN upgrade but now the react-native-gesture-handler build error is gone.

@Bort-777
Copy link

Bort-777 commented Apr 11, 2023

Downgraded Android Gradle Plugin: 7.3.1 (downgraded due to experiencing another issue with AGP 7.4.1 https://issuetracker.google.com/issues/232060576)

classpath("com.android.tools.build:gradle:7.3.1") looks resolve issue, but idk reasons how

gradle 7.4.1 as suggested for expo modules config cause the issue for me

@kaushal9808
Copy link

Same issues occur to me as well after enableNewArch=true. for
RN: 0.71.6
RNGH: 2.9.0

.gradle/caches/transforms-3/1d77430c69ac7afa83726261db6d41b1/transformed/jetified-react-android-0.71.6-release/prefab/modules/react_nativemodule_core/include/folly/small_vector.h:35:10: fatal error: 'boost/mpl/count.hpp' file not found
#include <boost/mpl/count.hpp>

@cycweeds
Copy link

cycweeds commented Apr 22, 2023

Downgraded Android Gradle Plugin: 7.3.1 (downgraded due to experiencing another issue with AGP 7.4.1 https://issuetracker.google.com/issues/232060576)

classpath("com.android.tools.build:gradle:7.3.1") looks resolve issue, but idk reasons how

gradle 7.4.1 as suggested for expo modules config cause the issue for me

it worked for me. update file build.gradle. and
set gradle version to 7.3.1 ---classpath("com.android.tools.build:gradle:7.3.1")

@Bort-777
Copy link

Bort-777 commented Apr 28, 2023

classpath("com.android.tools.build:gradle:7.3.1") looks resolve issue, but idk reasons how

An alternative workaround to the problems has been found: upgrade NDK: ndkVersion = "25.0.8775105"

@AlanSl
Copy link

AlanSl commented May 15, 2023

On React Native 0.72 release candidates, this seems to happen out of the box now with Fabric (probably because 0.72 stopped pinning the Android Gradle Plugin (AGP) to 7.3.1). Simple way to replicate the error:

  • Create a new 0.72.rc3 app: npx react-native@latest init RN0720RC3 --version 0.72.0-rc.3
  • Add react-native-gesture-handler: cd RN0720RC3; npm i react-native-gesture-handler
  • Set newArchEnabled=true in android/settings.gradle
  • Run the app: npx react-native run-android --deviceId YOUR_DEVICE_ID (verified on real device with id from adb devices; not tried on emulator)

In React Native 0.72, (or if you need AGP 7.4.2 for some other reason e.g. requirement of some native module), the best workaround is for now probably updating NDK as @Bort-777 suggests (ndkVersion = "25.0.8775105" in android/build.gradle replacing the existing ndk version). In React Native 0.71, I found classpath("com.android.tools.build:gradle:7.3.1") seemed more effective. May vary by app.

@emclab
Copy link

emclab commented May 27, 2023

same issue on RN 0.70.1 and RN gesture handler 2.10.1, MacOS 13.3. Any solution?

@Miyo-Excellent
Copy link

same issue on RN 0.72.0-rc3 and RN gesture handler 2.10.1, M1 MacOS 13.3. Any solution?

@Dverybest
Copy link

updating my android build.gradle buildscript to

buildscript {
    ext {
        buildToolsVersion = '33.0.0'
        minSdkVersion = 21
        compileSdkVersion = 33
        targetSdkVersion = 33
  }
....
}

as stated here https://stackoverflow.com/a/76409767/8523267 worked for me

@thanhloc-17
Copy link

thanhloc-17 commented Jun 12, 2023

same issue with

  • RN 0.72.0-rc.5
  • Expo 49,49.0.0-alpha.3
  • Reanimated: 3.3.0
  • newArchEnabled=true

@SahilJarial
Copy link

same issue .

@MihailsKostjuks
Copy link

Guys, just take this char ^ away. End result: "react-native-gesture-handler": "2.9.0"

@dnk332
Copy link

dnk332 commented Jul 3, 2023

Guys, just take this char ^ away. End result: "react-native-gesture-handler": "2.9.0"

thank, it worked for me. Can you explain why?

@mdarifulislamroni521
Copy link

android > build.gradle and replace by
ndkVersion = "25.2.9519653"

@mahshid22
Copy link

mahshid22 commented Jul 30, 2023

hi
i did all this steps mentioned above:
1-
buildscript {
ext {
buildToolsVersion = '33.0.0'
minSdkVersion = 21
compileSdkVersion = 33
targetSdkVersion = 33
}
....
}
2-
com.android.tools.build:gradle:7.3.1
3-
android > build.gradle and replace by
ndkVersion = "25.2.9519653"
and the errors gone
thanks to others
i hope this helped

@nubwang
Copy link

nubwang commented Aug 16, 2023

如果你绝望了,上面的方法都不行的话,你最后试试把android > gradle.properties下的newArchEnabled改成false,就离谱,我试了几天终于发现这个玩意老坑了,原因是 使用此属性可以启用对新体系结构的支持。这将允许您在应用程序中使用TurboModules和Fabric渲染。如果您想编写自定义TurboModule/Fabric组件或使用提供这些组件的库,则应启用此标志。

@Yandamuri
Copy link

Guys, just take this char ^ away. End result: "react-native-gesture-handler": "2.9.0"

what's your android targetsdk version?

@CarlosDanielDev
Copy link

While facing compilation issues in the React Native project, I identified that the error was related to the NDK and SDK configurations within Gradle. I resolved the issue by adjusting the versions in the Gradle configuration file as follows:

ndkVersion = "25.0.8775105"

buildscript {
  ext {
    targetSdkVersion  '33.0.0'
    buildToolsVersion = 33
    compileSdkVersion = 33
  }
}

This change fixed the compilation errors related to :react-native-gesture-handler:compileDebugKotlin and java.lang.StackOverflowError, allowing the build to complete successfully. This solution may be helpful for other developers facing similar issues with these specific versions of the NDK and SDK.

@vnknt
Copy link

vnknt commented Sep 10, 2023

Adding following property to gradle.properties file is worked for me.

kotlin.jvm.target.validation.mode=error

@berkaygurcan
Copy link

same issue and solutions doesnt work !

@kundakcii
Copy link

kundakcii commented Oct 8, 2023

same issue and solutions doesnt work !

can you try add this line at android/build.gradle file

dependencies {
     ...
    classpath("org.jetbrains.kotlin:kotlin-gradle-plugin:1.9.0")
}

do not forget to clean gradlew.

@ahmetcangurel
Copy link

same issue and solutions doesnt work !

can you try add this line at android/build.gradle file

dependencies {
     ...
    classpath("org.jetbrains.kotlin:kotlin-gradle-plugin:1.9.0")
}

if this not work. At the same time change ndk version to 25.0.8775105 and do not forget to clean gradlew.

it's worked for me, thanks

@aparnagude396
Copy link

Hi i got the same error I have upgraded react native version to 0.73.6. After that I'm getting this error can anyone help me this issue to be resolved.

  • What went wrong:
    Execution failed for task ':react-native-gesture-handler:compileDebugKotlin'.

A failure occurred while executing org.jetbrains.kotlin.compilerRunner.GradleCompilerRunnerWithWorkers$GradleKotlinCompilerWorkAction

@Excustic
Copy link

Excustic commented Apr 3, 2024

I managed to fix this problem by going to the gradle.properties of the library and changing this line

RNGH_kotlinVersion=1.6.21

to match my project's kotlin version which was 1.6.0

@Qdafengzi
Copy link

Qdafengzi commented May 23, 2024

same issue

ndkVersion:25.2.9519653
kotlin:2.0.0
react native:0.74.0
react-native-gesture-handler:2.16

        at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.lambda$executeIfValid$1(ExecuteActionsTaskExecuter.java:130)
        at org.gradle.internal.Try$Failure.ifSuccessfulOrElse(Try.java:282)
        at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.executeIfValid(ExecuteActionsTaskExecuter.java:128)
        at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.execute(ExecuteActionsTaskExecuter.java:116)
        at org.gradle.api.internal.tasks.execution.FinalizePropertiesTaskExecuter.execute(FinalizePropertiesTaskExecuter.java:46)
        at org.gradle.api.internal.tasks.execution.ResolveTaskExecutionModeExecuter.execute(ResolveTaskExecutionModeExecuter.java:51)
        at org.gradle.api.internal.tasks.execution.SkipTaskWithNoActionsExecuter.execute(SkipTaskWithNoActionsExecuter.java:57)
        at org.gradle.api.internal.tasks.execution.SkipOnlyIfTaskExecuter.execute(SkipOnlyIfTaskExecuter.java:74)
        at org.gradle.api.internal.tasks.execution.CatchExceptionTaskExecuter.execute(CatchExceptionTaskExecuter.java:36)
        at org.gradle.api.internal.tasks.execution.EventFiringTaskExecuter$1.executeTask(EventFiringTaskExecuter.java:77)
        at org.gradle.api.internal.tasks.execution.EventFiringTaskExecuter$1.call(EventFiringTaskExecuter.java:55)
        at org.gradle.api.internal.tasks.execution.EventFiringTaskExecuter$1.call(EventFiringTaskExecuter.java:52)
        at org.gradle.internal.operations.DefaultBuildOperationRunner$CallableBuildOperationWorker.execute(DefaultBuildOperationRunner.java:200)
        at org.gradle.internal.operations.DefaultBuildOperationRunner$CallableBuildOperationWorker.execute(DefaultBuildOperationRunner.java:195)
        at org.gradle.internal.operations.DefaultBuildOperationRunner$2.execute(DefaultBuildOperationRunner.java:66)
        at org.gradle.internal.operations.DefaultBuildOperationRunner$2.execute(DefaultBuildOperationRunner.java:59)
        at org.gradle.internal.operations.DefaultBuildOperationRunner.execute(DefaultBuildOperationRunner.java:157)
        at org.gradle.internal.operations.DefaultBuildOperationRunner.execute(DefaultBuildOperationRunner.java:59)
        at org.gradle.internal.operations.DefaultBuildOperationRunner.call(DefaultBuildOperationRunner.java:53)
        at org.gradle.internal.operations.DefaultBuildOperationExecutor.call(DefaultBuildOperationExecutor.java:73)
        at org.gradle.api.internal.tasks.execution.EventFiringTaskExecuter.execute(EventFiringTaskExecuter.java:52)
        at org.gradle.execution.plan.LocalTaskNodeExecutor.execute(LocalTaskNodeExecutor.java:42)
        at org.gradle.execution.taskgraph.DefaultTaskExecutionGraph$InvokeNodeExecutorsAction.execute(DefaultTaskExecutionGraph.java:331)
        at org.gradle.execution.taskgraph.DefaultTaskExecutionGraph$InvokeNodeExecutorsAction.execute(DefaultTaskExecutionGraph.java:318)
        at org.gradle.execution.taskgraph.DefaultTaskExecutionGraph$BuildOperationAwareExecutionAction.lambda$execute$0(DefaultTaskExecutionGraph.java:314)
        at org.gradle.internal.operations.CurrentBuildOperationRef.with(CurrentBuildOperationRef.java:80)
        at org.gradle.execution.taskgraph.DefaultTaskExecutionGraph$BuildOperationAwareExecutionAction.execute(DefaultTaskExecutionGraph.java:314)
        at org.gradle.execution.taskgraph.DefaultTaskExecutionGraph$BuildOperationAwareExecutionAction.execute(DefaultTaskExecutionGraph.java:303)
        at org.gradle.execution.plan.DefaultPlanExecutor$ExecutorWorker.execute(DefaultPlanExecutor.java:463)
        at org.gradle.execution.plan.DefaultPlanExecutor$ExecutorWorker.run(DefaultPlanExecutor.java:380)
        at org.gradle.internal.concurrent.ExecutorPolicy$CatchAndRecordFailures.onExecute(ExecutorPolicy.java:64)
        at org.gradle.internal.concurrent.AbstractManagedExecutor$1.run(AbstractManagedExecutor.java:47)
Caused by: org.gradle.workers.internal.DefaultWorkerExecutor$WorkExecutionException: A failure occurred while executing org.jetbrains.kotlin.compilerRunner.GradleCompilerRunnerWithWorkers$GradleKotlinCompilerWorkAction
        at org.gradle.workers.internal.DefaultWorkerExecutor$WorkItemExecution.waitForCompletion(DefaultWorkerExecutor.java:287)
        at org.gradle.internal.work.DefaultAsyncWorkTracker.lambda$waitForItemsAndGatherFailures$2(DefaultAsyncWorkTracker.java:130)
        at org.gradle.internal.Factories$1.create(Factories.java:31)
        at org.gradle.internal.work.DefaultWorkerLeaseService.withoutLocks(DefaultWorkerLeaseService.java:336)
        at org.gradle.internal.work.DefaultWorkerLeaseService.withoutLocks(DefaultWorkerLeaseService.java:319)
        at org.gradle.internal.work.DefaultWorkerLeaseService.withoutLock(DefaultWorkerLeaseService.java:324)
        at org.gradle.internal.work.DefaultAsyncWorkTracker.waitForItemsAndGatherFailures(DefaultAsyncWorkTracker.java:126)
        at org.gradle.internal.work.DefaultAsyncWorkTracker.waitForItemsAndGatherFailures(DefaultAsyncWorkTracker.java:92)
        at org.gradle.internal.work.DefaultAsyncWorkTracker.waitForAll(DefaultAsyncWorkTracker.java:78)
        at org.gradle.internal.work.DefaultAsyncWorkTracker.waitForCompletion(DefaultAsyncWorkTracker.java:66)
        at org.gradle.api.internal.tasks.execution.TaskExecution$3.run(TaskExecution.java:252)
        at org.gradle.internal.operations.DefaultBuildOperationRunner$1.execute(DefaultBuildOperationRunner.java:29)
        at org.gradle.internal.operations.DefaultBuildOperationRunner$1.execute(DefaultBuildOperationRunner.java:26)
        at org.gradle.internal.operations.DefaultBuildOperationRunner$2.execute(DefaultBuildOperationRunner.java:66)
        at org.gradle.internal.operations.DefaultBuildOperationRunner$2.execute(DefaultBuildOperationRunner.java:59)
        at org.gradle.internal.operations.DefaultBuildOperationRunner.execute(DefaultBuildOperationRunner.java:157)
        at org.gradle.internal.operations.DefaultBuildOperationRunner.execute(DefaultBuildOperationRunner.java:59)
        at org.gradle.internal.operations.DefaultBuildOperationRunner.run(DefaultBuildOperationRunner.java:47)
        at org.gradle.internal.operations.DefaultBuildOperationExecutor.run(DefaultBuildOperationExecutor.java:68)
        at org.gradle.api.internal.tasks.execution.TaskExecution.executeAction(TaskExecution.java:229)
        at org.gradle.api.internal.tasks.execution.TaskExecution.executeActions(TaskExecution.java:212)
        at org.gradle.api.internal.tasks.execution.TaskExecution.executeWithPreviousOutputFiles(TaskExecution.java:195)
        at org.gradle.api.internal.tasks.execution.TaskExecution.execute(TaskExecution.java:162)
        at org.gradle.internal.execution.steps.ExecuteStep.executeInternal(ExecuteStep.java:105)
        at org.gradle.internal.execution.steps.ExecuteStep.access$000(ExecuteStep.java:44)
        at org.gradle.internal.execution.steps.ExecuteStep$1.call(ExecuteStep.java:59)
        at org.gradle.internal.execution.steps.ExecuteStep$1.call(ExecuteStep.java:56)
        at org.gradle.internal.operations.DefaultBuildOperationRunner$CallableBuildOperationWorker.execute(DefaultBuildOperationRunner.java:200)
        at org.gradle.internal.operations.DefaultBuildOperationRunner$CallableBuildOperationWorker.execute(DefaultBuildOperationRunner.java:195)
        at org.gradle.internal.operations.DefaultBuildOperationRunner$2.execute(DefaultBuildOperationRunner.java:66)
        at org.gradle.internal.operations.DefaultBuildOperationRunner$2.execute(DefaultBuildOperationRunner.java:59)
        at org.gradle.internal.operations.DefaultBuildOperationRunner.execute(DefaultBuildOperationRunner.java:157)
        at org.gradle.internal.operations.DefaultBuildOperationRunner.execute(DefaultBuildOperationRunner.java:59)
        at org.gradle.internal.operations.DefaultBuildOperationRunner.call(DefaultBuildOperationRunner.java:53)
        at org.gradle.internal.operations.DefaultBuildOperationExecutor.call(DefaultBuildOperationExecutor.java:73)
        at org.gradle.internal.execution.steps.ExecuteStep.execute(ExecuteStep.java:56)
        at org.gradle.internal.execution.steps.ExecuteStep.execute(ExecuteStep.java:44)
        at org.gradle.internal.execution.steps.CancelExecutionStep.execute(CancelExecutionStep.java:41)
        at org.gradle.internal.execution.steps.TimeoutStep.executeWithoutTimeout(TimeoutStep.java:74)
        at org.gradle.internal.execution.steps.TimeoutStep.execute(TimeoutStep.java:55)
        at org.gradle.internal.execution.steps.PreCreateOutputParentsStep.execute(PreCreateOutputParentsStep.java:50)
        at org.gradle.internal.execution.steps.PreCreateOutputParentsStep.execute(PreCreateOutputParentsStep.java:28)
        at org.gradle.internal.execution.steps.RemovePreviousOutputsStep.execute(RemovePreviousOutputsStep.java:67)
        at org.gradle.internal.execution.steps.RemovePreviousOutputsStep.execute(RemovePreviousOutputsStep.java:37)
        at org.gradle.internal.execution.steps.BroadcastChangingOutputsStep.execute(BroadcastChangingOutputsStep.java:61)
        at org.gradle.internal.execution.steps.BroadcastChangingOutputsStep.execute(BroadcastChangingOutputsStep.java:26)
        at org.gradle.internal.execution.steps.CaptureOutputsAfterExecutionStep.execute(CaptureOutputsAfterExecutionStep.java:67)
        at org.gradle.internal.execution.steps.CaptureOutputsAfterExecutionStep.execute(CaptureOutputsAfterExecutionStep.java:45)
        at org.gradle.internal.execution.steps.ResolveInputChangesStep.execute(ResolveInputChangesStep.java:40)
        at org.gradle.internal.execution.steps.ResolveInputChangesStep.execute(ResolveInputChangesStep.java:29)
        at org.gradle.internal.execution.steps.BuildCacheStep.executeWithoutCache(BuildCacheStep.java:189)
        at org.gradle.internal.execution.steps.BuildCacheStep.lambda$execute$1(BuildCacheStep.java:75)
        at org.gradle.internal.Either$Right.fold(Either.java:175)
        at org.gradle.internal.execution.caching.CachingState.fold(CachingState.java:62)
        at org.gradle.internal.execution.steps.BuildCacheStep.execute(BuildCacheStep.java:73)
        at org.gradle.internal.execution.steps.BuildCacheStep.execute(BuildCacheStep.java:48)
        at org.gradle.internal.execution.steps.StoreExecutionStateStep.execute(StoreExecutionStateStep.java:46)
        at org.gradle.internal.execution.steps.StoreExecutionStateStep.execute(StoreExecutionStateStep.java:35)
        at org.gradle.internal.execution.steps.SkipUpToDateStep.executeBecause(SkipUpToDateStep.java:76)
        at org.gradle.internal.execution.steps.SkipUpToDateStep.lambda$execute$2(SkipUpToDateStep.java:54)
        at org.gradle.internal.execution.steps.SkipUpToDateStep.execute(SkipUpToDateStep.java:54)
        at org.gradle.internal.execution.steps.SkipUpToDateStep.execute(SkipUpToDateStep.java:36)
        at org.gradle.internal.execution.steps.legacy.MarkSnapshottingInputsFinishedStep.execute(MarkSnapshottingInputsFinishedStep.java:37)
        at org.gradle.internal.execution.steps.legacy.MarkSnapshottingInputsFinishedStep.execute(MarkSnapshottingInputsFinishedStep.java:27)
        at org.gradle.internal.execution.steps.ResolveIncrementalCachingStateStep.executeDelegate(ResolveIncrementalCachingStateStep.java:49)
        at org.gradle.internal.execution.steps.ResolveIncrementalCachingStateStep.executeDelegate(ResolveIncrementalCachingStateStep.java:27)
        at org.gradle.internal.execution.steps.AbstractResolveCachingStateStep.execute(AbstractResolveCachingStateStep.java:71)
        at org.gradle.internal.execution.steps.AbstractResolveCachingStateStep.execute(AbstractResolveCachingStateStep.java:39)
        at org.gradle.internal.execution.steps.ResolveChangesStep.execute(ResolveChangesStep.java:65)
        at org.gradle.internal.execution.steps.ResolveChangesStep.execute(ResolveChangesStep.java:36)
        at org.gradle.internal.execution.steps.ValidateStep.execute(ValidateStep.java:106)
        at org.gradle.internal.execution.steps.ValidateStep.execute(ValidateStep.java:55)
        at org.gradle.internal.execution.steps.AbstractCaptureStateBeforeExecutionStep.execute(AbstractCaptureStateBeforeExecutionStep.java:64)
        at org.gradle.internal.execution.steps.AbstractCaptureStateBeforeExecutionStep.execute(AbstractCaptureStateBeforeExecutionStep.java:43)
        at org.gradle.internal.execution.steps.AbstractSkipEmptyWorkStep.executeWithNonEmptySources(AbstractSkipEmptyWorkStep.java:125)
        at org.gradle.internal.execution.steps.AbstractSkipEmptyWorkStep.execute(AbstractSkipEmptyWorkStep.java:61)
        at org.gradle.internal.execution.steps.AbstractSkipEmptyWorkStep.execute(AbstractSkipEmptyWorkStep.java:36)
        at org.gradle.internal.execution.steps.legacy.MarkSnapshottingInputsStartedStep.execute(MarkSnapshottingInputsStartedStep.java:38)
        at org.gradle.internal.execution.steps.LoadPreviousExecutionStateStep.execute(LoadPreviousExecutionStateStep.java:36)
        at org.gradle.internal.execution.steps.LoadPreviousExecutionStateStep.execute(LoadPreviousExecutionStateStep.java:23)
        at org.gradle.internal.execution.steps.HandleStaleOutputsStep.execute(HandleStaleOutputsStep.java:75)
        at org.gradle.internal.execution.steps.HandleStaleOutputsStep.execute(HandleStaleOutputsStep.java:41)
        at org.gradle.internal.execution.steps.AssignMutableWorkspaceStep.lambda$execute$0(AssignMutableWorkspaceStep.java:35)
        at org.gradle.api.internal.tasks.execution.TaskExecution$4.withWorkspace(TaskExecution.java:289)
        at org.gradle.internal.execution.steps.AssignMutableWorkspaceStep.execute(AssignMutableWorkspaceStep.java:31)
        at org.gradle.internal.execution.steps.AssignMutableWorkspaceStep.execute(AssignMutableWorkspaceStep.java:22)
        at org.gradle.internal.execution.steps.ChoosePipelineStep.execute(ChoosePipelineStep.java:40)
        at org.gradle.internal.execution.steps.ChoosePipelineStep.execute(ChoosePipelineStep.java:23)
        at org.gradle.internal.execution.steps.ExecuteWorkBuildOperationFiringStep.lambda$execute$2(ExecuteWorkBuildOperationFiringStep.java:67)
        at org.gradle.internal.execution.steps.ExecuteWorkBuildOperationFiringStep.execute(ExecuteWorkBuildOperationFiringStep.java:67)
        at org.gradle.internal.execution.steps.ExecuteWorkBuildOperationFiringStep.execute(ExecuteWorkBuildOperationFiringStep.java:39)
        at org.gradle.internal.execution.steps.IdentityCacheStep.execute(IdentityCacheStep.java:46)
        at org.gradle.internal.execution.steps.IdentityCacheStep.execute(IdentityCacheStep.java:34)
        at org.gradle.internal.execution.steps.IdentifyStep.execute(IdentifyStep.java:48)
        at org.gradle.internal.execution.steps.IdentifyStep.execute(IdentifyStep.java:35)
        at org.gradle.internal.execution.impl.DefaultExecutionEngine$1.execute(DefaultExecutionEngine.java:61)
        at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.executeIfValid(ExecuteActionsTaskExecuter.java:127)
        at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.execute(ExecuteActionsTaskExecuter.java:116)
        at org.gradle.api.internal.tasks.execution.FinalizePropertiesTaskExecuter.execute(FinalizePropertiesTaskExecuter.java:46)
        at org.gradle.api.internal.tasks.execution.ResolveTaskExecutionModeExecuter.execute(ResolveTaskExecutionModeExecuter.java:51)
        at org.gradle.api.internal.tasks.execution.SkipTaskWithNoActionsExecuter.execute(SkipTaskWithNoActionsExecuter.java:57)
        at org.gradle.api.internal.tasks.execution.SkipOnlyIfTaskExecuter.execute(SkipOnlyIfTaskExecuter.java:74)
        at org.gradle.api.internal.tasks.execution.CatchExceptionTaskExecuter.execute(CatchExceptionTaskExecuter.java:36)
        at org.gradle.api.internal.tasks.execution.EventFiringTaskExecuter$1.executeTask(EventFiringTaskExecuter.java:77)
        at org.gradle.api.internal.tasks.execution.EventFiringTaskExecuter$1.call(EventFiringTaskExecuter.java:55)
        at org.gradle.api.internal.tasks.execution.EventFiringTaskExecuter$1.call(EventFiringTaskExecuter.java:52)
        at org.gradle.internal.operations.DefaultBuildOperationRunner$CallableBuildOperationWorker.execute(DefaultBuildOperationRunner.java:200)
        at org.gradle.internal.operations.DefaultBuildOperationRunner$CallableBuildOperationWorker.execute(DefaultBuildOperationRunner.java:195)
        at org.gradle.internal.operations.DefaultBuildOperationRunner$2.execute(DefaultBuildOperationRunner.java:66)
        at org.gradle.internal.operations.DefaultBuildOperationRunner$2.execute(DefaultBuildOperationRunner.java:59)
        at org.gradle.internal.operations.DefaultBuildOperationRunner.execute(DefaultBuildOperationRunner.java:157)
        at org.gradle.internal.operations.DefaultBuildOperationRunner.execute(DefaultBuildOperationRunner.java:59)
        at org.gradle.internal.operations.DefaultBuildOperationRunner.call(DefaultBuildOperationRunner.java:53)
        at org.gradle.internal.operations.DefaultBuildOperationExecutor.call(DefaultBuildOperationExecutor.java:73)
        at org.gradle.api.internal.tasks.execution.EventFiringTaskExecuter.execute(EventFiringTaskExecuter.java:52)
        at org.gradle.execution.plan.LocalTaskNodeExecutor.execute(LocalTaskNodeExecutor.java:42)
        at org.gradle.execution.taskgraph.DefaultTaskExecutionGraph$InvokeNodeExecutorsAction.execute(DefaultTaskExecutionGraph.java:331)
        at org.gradle.execution.taskgraph.DefaultTaskExecutionGraph$InvokeNodeExecutorsAction.execute(DefaultTaskExecutionGraph.java:318)
        at org.gradle.execution.taskgraph.DefaultTaskExecutionGraph$BuildOperationAwareExecutionAction.lambda$execute$0(DefaultTaskExecutionGraph.java:314)
        at org.gradle.internal.operations.CurrentBuildOperationRef.with(CurrentBuildOperationRef.java:80)
        at org.gradle.execution.taskgraph.DefaultTaskExecutionGraph$BuildOperationAwareExecutionAction.execute(DefaultTaskExecutionGraph.java:314)
        at org.gradle.execution.taskgraph.DefaultTaskExecutionGraph$BuildOperationAwareExecutionAction.execute(DefaultTaskExecutionGraph.java:303)
        at org.gradle.execution.plan.DefaultPlanExecutor$ExecutorWorker.execute(DefaultPlanExecutor.java:463)
        at org.gradle.execution.plan.DefaultPlanExecutor$ExecutorWorker.run(DefaultPlanExecutor.java:380)
        at org.gradle.internal.concurrent.ExecutorPolicy$CatchAndRecordFailures.onExecute(ExecutorPolicy.java:64)
        at org.gradle.internal.concurrent.AbstractManagedExecutor$1.run(AbstractManagedExecutor.java:47)
Caused by: org.jetbrains.kotlin.gradle.tasks.CompilationErrorException: Compilation error. See log for more details
        at org.jetbrains.kotlin.gradle.tasks.TasksUtilsKt.throwExceptionIfCompilationFailed(tasksUtils.kt:21)
        at org.jetbrains.kotlin.compilerRunner.GradleKotlinCompilerWork.run(GradleKotlinCompilerWork.kt:119)
        at org.jetbrains.kotlin.compilerRunner.GradleCompilerRunnerWithWorkers$GradleKotlinCompilerWorkAction.execute(GradleCompilerRunnerWithWorkers.kt:76)
        at org.gradle.workers.internal.DefaultWorkerServer.execute(DefaultWorkerServer.java:63)
        at org.gradle.workers.internal.NoIsolationWorkerFactory$1$1.create(NoIsolationWorkerFactory.java:66)
        at org.gradle.workers.internal.NoIsolationWorkerFactory$1$1.create(NoIsolationWorkerFactory.java:62)
        at org.gradle.internal.classloader.ClassLoaderUtils.executeInClassloader(ClassLoaderUtils.java:100)
        at org.gradle.workers.internal.NoIsolationWorkerFactory$1.lambda$execute$0(NoIsolationWorkerFactory.java:62)
        at org.gradle.workers.internal.AbstractWorker$1.call(AbstractWorker.java:44)
        at org.gradle.workers.internal.AbstractWorker$1.call(AbstractWorker.java:41)
        at org.gradle.internal.operations.DefaultBuildOperationRunner$CallableBuildOperationWorker.execute(DefaultBuildOperationRunner.java:200)
        at org.gradle.internal.operations.DefaultBuildOperationRunner$CallableBuildOperationWorker.execute(DefaultBuildOperationRunner.java:195)
        at org.gradle.internal.operations.DefaultBuildOperationRunner$2.execute(DefaultBuildOperationRunner.java:66)
        at org.gradle.internal.operations.DefaultBuildOperationRunner$2.execute(DefaultBuildOperationRunner.java:59)
        at org.gradle.internal.operations.DefaultBuildOperationRunner.execute(DefaultBuildOperationRunner.java:157)
        at org.gradle.internal.operations.DefaultBuildOperationRunner.execute(DefaultBuildOperationRunner.java:59)
        at org.gradle.internal.operations.DefaultBuildOperationRunner.call(DefaultBuildOperationRunner.java:53)
        at org.gradle.internal.operations.DefaultBuildOperationExecutor.call(DefaultBuildOperationExecutor.java:73)
        at org.gradle.workers.internal.AbstractWorker.executeWrappedInBuildOperation(AbstractWorker.java:41)
        at org.gradle.workers.internal.NoIsolationWorkerFactory$1.execute(NoIsolationWorkerFactory.java:59)
        at org.gradle.workers.internal.DefaultWorkerExecutor.lambda$submitWork$0(DefaultWorkerExecutor.java:174)
        at org.gradle.internal.work.DefaultConditionalExecutionQueue$ExecutionRunner.runExecution(DefaultConditionalExecutionQueue.java:187)
        at org.gradle.internal.work.DefaultConditionalExecutionQueue$ExecutionRunner.access$700(DefaultConditionalExecutionQueue.java:120)
        at org.gradle.internal.work.DefaultConditionalExecutionQueue$ExecutionRunner$1.run(DefaultConditionalExecutionQueue.java:162)
        at org.gradle.internal.Factories$1.create(Factories.java:31)
        at org.gradle.internal.work.DefaultWorkerLeaseService.withLocks(DefaultWorkerLeaseService.java:264)
        at org.gradle.internal.work.DefaultWorkerLeaseService.runAsWorkerThread(DefaultWorkerLeaseService.java:128)
        at org.gradle.internal.work.DefaultWorkerLeaseService.runAsWorkerThread(DefaultWorkerLeaseService.java:133)
        at org.gradle.internal.work.DefaultConditionalExecutionQueue$ExecutionRunner.runBatch(DefaultConditionalExecutionQueue.java:157)
        at org.gradle.internal.work.DefaultConditionalExecutionQueue$ExecutionRunner.run(DefaultConditionalExecutionQueue.java:126)
        ... 2 more

@Qdafengzi
Copy link

I have fixed this error

error is

e: file:///Users/xxx/Documents/Project/rnApp/node_modules/react-native-gesture-handler/android/src/main/java/com/swmansion/gesturehandler/core/GestureHandlerOrchestrator.kt:619:30 Only safe (?.) or non-null asserted (!!.) calls are allowed on a nullable receiver of type 'com.swmansion.gesturehandler.core.GestureHandler<*>?'.
e: file:///Users/xxx/Documents/Project/rnApp/node_modules/react-native-gesture-handler/android/src/main/java/com/swmansion/gesturehandler/core/GestureHandlerOrchestrator.kt:619:44 Only safe (?.) or non-null asserted (!!.) calls are allowed on a nullable receiver of type 'com.swmansion.gesturehandler.core.GestureHandler<*>?'.
e: file:///Users/xxx/Documents/Project/rnApp/node_modules/react-native-gesture-handler/android/src/main/java/com/swmansion/gesturehandler/core/GestureHandlerOrchestrator.kt:619:58 Only safe (?.) or non-null asserted (!!.) calls are allowed on a nullable receiver of type 'com.swmansion.gesturehandler.core.GestureHandler<*>?'.
e: file:///Users/xxx/Documents/Project/rnApp/node_modules/react-native-gesture-handler/android/src/main/java/com/swmansion/gesturehandler/core/GestureHandlerOrchestrator.kt:619:74 Only safe (?.) or non-null asserted (!!.) calls are allowed on a nullable receiver of type 'com.swmansion.gesturehandler.core.GestureHandler<*>?'.
e: file:///Users/xxx/Documents/Project/rnApp/node_modules/react-native-gesture-handler/android/src/main/java/com/swmansion/gesturehandler/core/GestureHandlerOrchestrator.kt:622:25 Only safe (?.) or non-null asserted (!!.) calls are allowed on a nullable receiver of type 'com.swmansion.gesturehandler.core.GestureHandler<*>?'.
e: file:///Users/xxx/Documents/Project/rnApp/node_modules/react-native-gesture-handler/android/src/main/java/com/swmansion/gesturehandler/core/GestureHandlerOrchestrator.kt:622:45 Only safe (?.) or non-null asserted (!!.) calls are allowed on a nullable receiver of type 'com.swmansion.gesturehandler.core.GestureHandler<*>?'.
e: file:///Users/xxx/Documents/Project/rnApp/node_modules/react-native-gesture-handler/android/src/main/java/com/swmansion/gesturehandler/core/GestureHandlerOrchestrator.kt:623:19 Only safe (?.) or non-null asserted (!!.) calls are allowed on a nullable receiver of type 'com.swmansion.gesturehandler.core.GestureHandler<*>?'.
e: file:///Users/xxx/Documents/Project/rnApp/node_modules/react-native-gesture-handler/android/src/main/java/com/swmansion/gesturehandler/core/GestureHandlerOrchestrator.kt:625:19 Only safe (?.) or non-null asserted (!!.) calls are allowed on a nullable receiver of type 'com.swmansion.gesturehandler.core.GestureHandler<*>?'.
e: file:///Users/xxx/Documents/Project/rnApp/node_modules/react-native-gesture-handler/android/src/main/java/com/swmansion/gesturehandler/core/GestureHandlerOrchestrator.kt:627:19 Only safe (?.) or non-null asserted (!!.) calls are allowed on a nullable receiver of type 'com.swmansion.gesturehandler.core.GestureHandler<*>?'.
e: file:///Users/xxx/Documents/Project/rnApp/node_modules/react-native-gesture-handler/android/src/main/java/com/swmansion/gesturehandler/core/GestureHandlerOrchestrator.kt:629:19 Only safe (?.) or non-null asserted (!!.) calls are allowed on a nullable receiver of type 'com.swmansion.gesturehandler.core.GestureHandler<*>?'.
private val handlersComparator = Comparator<GestureHandler<*>?> { a, b ->
      return@Comparator if (a!=null && a.isActive && b!!.isActive || a!=null && a.isAwaiting && b!!.isAwaiting) {
        // both A and B are either active or awaiting activation, in which case we prefer one that
        // has activated (or turned into "awaiting" state) earlier
        Integer.signum(b.activationIndex - a.activationIndex)
      } else if (a!=null &&a.isActive) {
        -1 // only A is active
      } else if (b!=null && b.isActive) {
        1 // only B is active
      } else if (a!=null &&a.isAwaiting) {
        -1 // only A is awaiting, B is inactive
      } else if (b!=null && b.isAwaiting) {
        1 // only B is awaiting, A is inactive
      } else {
        0 // both A and B are inactive, stable order matters
      }
    }

@j-piasecki
Copy link
Member

The last error is fixed by #2964. If you have any other build issues please open a new issue with a reproducer.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Missing info Platform: Android This issue is specific to Android Repro provided A reproduction with a snack or repo is provided
Projects
None yet
Development

No branches or pull requests