Log unhandled promise rejections using sentry-expo?

I have configured sentry-expo in a newly created bare project, and while I’m able to log issues using Sentry.Native.captureException, it looks like unhandled errors coming from Promises are not logged at all.

For example:

new Promise(() => { throw new Error('This error will not be logged by Sentry!')});

As I understand, they should be logged as well, but I can’t seem to get them to work.

this should be accomplished by the ReactNativeErrorHandlers integration, which we add by default in sentry-expo here. Are you providing your own integrations at all?

Hi Charlie, I don’t have any extra integrations. It’s a completely new bare project, nothing added but the setup of sentry-expo.

And if you don’t use sentry-expo, but instead just use @sentry/react-native, are those same promise rejections caught and logged to sentry?

Using @sentry/react-native has the same issue. I checked the generated files from the sentry-wizard and everything looks fine. Still, no unhandled rejections are logged. Would a link to the source code help?

Thanks for checking that! If just using @sentry/react-native has the same issue, you may want to post either on their forums, or open a bug report on their repo