0
votes

I'm on MacOS trying to run a react native (0.59.9) app on Android emulator. I've integrated Sentry using the wizard. Works fine on iPhone. On Android, this happens:

I try to run the app w/ react-native run-android

Build fails.

A problem occurred configuring project ':@sentry_react-native'. SDK location not found. Define location with sdk.dir in the local.properties file or with an ANDROID_HOME environment variable.

I go into the android folder and create a local.properties file and paste this in: sdk.dir=C:/Users/my_name/Library/Android/sdk

I try again to run the app w/ react-native run-android Build fails.

A problem occurred configuring project ':@sentry_react-native'. The SDK directory '/Users/my_name/project_path/android/C:/Users/my_name/Library/Android/sdk' does not exist.

Why is it concatenating the SDK dir w/ my project path? That doesn't make sense to me. How do I fix this?

1

1 Answers

0
votes

this isn't a Sentry issue, but an Android environment issue, please look at https://reactnative.dev/docs/getting-started.html and set your Android env. properly. Look for "Android development environment", good luck :)