sentry-react-native: Task :react-native-sentry:compileDebugJavaWithJavac FAILED

OS:

  • Windows
  • [ x] MacOS
  • Linux

Platform:

  • iOS
  • [x ] Android

Output of node -v && npm -v && npm ls --prod --depth=0

v11.10.1
6.7.0
NFIBEngage@1.0.7 /Users/danale/Projects/engage-application.mobile
├── appcenter@2.0.0
├── appcenter-analytics@2.0.0
├── appcenter-crashes@2.0.0
├── axios@0.16.2
├── date-fns@1.30.1
├── lodash@4.17.4
├── moment@2.20.1
├── payment@2.3.0
├── prop-types@15.6.0
├── react@16.8.3
├── react-native@0.59.9
├── react-native-autoheight-webview@0.6.1
├── react-native-calendar-events@1.6.1
├── react-native-device-info@0.21.5
├── react-native-exception-handler@2.8.9
├── react-native-image-progress@1.0.1
├── react-native-immediate-phone-call@1.0.0
├── react-native-input-scroll-view@1.6.7
├── react-native-keyboard-aware-scroll-view@0.4.4
├── react-native-keyboard-manager@4.0.13-7
├── react-native-material-buttons@0.5.0
├── react-native-material-dropdown@0.5.2
├── react-native-material-tabs@3.5.0
├── react-native-material-textfield@0.10.0
├── react-native-onesignal@3.0.7
├── react-native-popup-menu@0.8.3
├── react-native-sentry@0.32.0
├── react-native-size-matters@0.1.0
├── react-native-splash-screen@3.0.6
├── react-native-svg@6.3.1
├── react-native-swipe-view@3.0.1 (git+https://github.com/jjd314/react-native-swipe-view.git#123120431aaba5fddccc1eeea2903c6ca0029550)
├── react-native-tab-view@1.3.2
├── react-native-vector-icons@6.1.0
├── react-native-xcode-packager@0.1.0
├── react-navigation@1.5.11
├── react-redux@5.0.6
├── reactotron-react-native@3.5.0
├── reactotron-redux@3.1.0
├── recompose@0.26.0
├── UNMET PEER DEPENDENCY redux@4.0.1
├── redux-thunk@2.2.0
└── replace-in-file@3.1.1

npm ERR! peer dep missing: redux@^2.0.0 || ^3.0.0, required by react-redux@5.0.6
npm ERR! invalid: react-native-tab-view@0.0.74 /Users/danale/Projects/engage-application.mobile/node_modules/react-navigation/node_modules/react-native-tab-view

Config:

Sentry.config("__DSN__").install();

I have following issue:

I try to run react-native run-android and I get the following error:

> Task :react-native-sentry:compileDebugJavaWithJavac FAILED
/Users/danale/Projects/engage-application.mobile/node_modules/react-native-sentry/android/src/main/java/io/sentry/RNSentryModule.java:252: error: incompatible types: ReadableArray cannot be converted to ReadableNativeArray
            addExceptionInterface(eventBuilder, exception.getString("type"), exception.getString("value"), stacktrace.getArray("frames"));
                                                                                                                              ^
Note: /Users/danale/Projects/engage-application.mobile/node_modules/react-native-sentry/android/src/main/java/io/sentry/RNSentryModule.java uses or overrides 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: Some messages have been simplified; recompile with -Xdiags:verbose to get full output
1 error

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':react-native-sentry:compileDebugJavaWithJavac'.
> Compilation failed; see the compiler error output for details.

Steps to reproduce: I run gradle :app:installDevDebug from within `./android’

Actual result: I continue to get the above error.

Expected result:

  • Expected result is that the android build is successful and I can open an android emulator and click on the app.

About this issue

  • Original URL
  • State: closed
  • Created 5 years ago
  • Comments: 21 (3 by maintainers)

Most upvoted comments

I just found a solution, downgrade @sentry/react-native to 1.0.6.