Task :app:bundleReleaseJsAndAssets_SentryUpload FAILED

Viewed 885

I'm facing this issue when compiling APK in react-native,

This issue happens only when generating a release APK and the app works fine on debug mode.

It seems that the path to global node modules is wrong ( Not in Desktop ).

enter image description here

2 Answers

I solved this problem by following this steps:

1- Installing sentry-cli globally

sudo npm install -g @sentry/cli --unsafe-perm

2- Login in sentry with the sentry cli installed by

sentry-cli login

3- Updating my android/sentry.properties with the new token generated

defaults.url=https://sentry.io/
defaults.org=my-organization
defaults.project=my-project
auth.token=new_token

I have fixed this by synchronizing with Gradle files.

Related