Closed ammar-madni closed 1 month ago
Passing over to the hermes team
Hi, we are unable to investigate problems without a minimal repro, plus this doesn't look like a bug in Hermes - Hermes exposes Promise.allSettled().
However from a cursory glance it looks like you are using a Promise polyfill, not the Promise provided by Hermes, judging by the following lines in your stack trace:
at tryCallTwo(/node_modules/promise/setimmediate/core.js:45:7)
at doResolve(/node_modules/promise/setimmediate/core.js:200:23)
at Promise(/node_modules/promise/setimmediate/core.js:66:12)
Description
Our Sentry logs are showing multiple error events when calling
Promise.allSettled
with the error beingundefined is not a function
.I can't replicate the issue locally, only seems to happen in production.
https://github.com/facebook/react-native/issues/35363
Steps to reproduce
1.- Setup a blank react native app. 2.- Use Promise.allSettled. 3.- Build the app for production. 4.- Get [TypeError: undefined is not a function].
React Native Version
0.74.5
Affected Platforms
Runtime - Android, Runtime - iOS
Output of
npx react-native info
Stacktrace or Logs
Reproducer
https://github.com/ammar-madni/promise-all-settled-undefined
Screenshots and Videos