ExceptionsManager.handleException is not a function
See original GitHub issueDescribe the bug
We recently upgraded to React Native 0.63, Jest 26, and React Native Testing Library 7. When running jest with --runInBand
we have noticed the following error randomly in our CI:
/node_modules/react-native/Libraries/LogBox/Data/LogBoxData.js:104
ExceptionsManager.handleException(error, true);
^
TypeError: ExceptionsManager.handleException is not a function
at reportLogBoxError (/node_modules/react-native/Libraries/LogBox/Data/LogBoxData.js:108:21)
at Immediate.<anonymous> (/node_modules/react-native/Libraries/LogBox/Data/LogBoxData.js:217:7)
at processImmediate (internal/timers.js:456:21)
I noticed a similar error in the previous project: https://github.com/testing-library/native-testing-library/issues/132
Any thoughts?
Expected behavior
No errors.
Versions
❯ npx envinfo --npmPackages react,react-native,react-test-renderer,@testing-library/react-native
npmPackages:
@testing-library/react-native: 7.0.2 => 7.0.2
react: 16.13.1 => 16.13.1
react-native: 0.63.2 => 0.63.2
react-test-renderer: 16.13.1 => 16.13.1
Issue Analytics
- State:
- Created 3 years ago
- Reactions:3
- Comments:5 (2 by maintainers)
Top Results From Across the Web
ExceptionsManager.handleException is not a function #29849
We recently upgraded to React Native 0.63, Jest 26, and React Native Testing Library 7. When running jest with --runInBand we have noticed ......
Read more >Getting 'TypeError: interpolate is not a function' in React-Native
Open the Drawer.js file found in the <project folder>/node_modules/react-navigation-drawer/lib/module/views/ folder. · You will find interpolate ...
Read more >Expo-google-sign-in doesn't seem to work.
It's failing at line 93 of Expo.js where it's trying to return GoogleSignIn. Object.defineProperty(exports, "GoogleSignIn", { enumerable: true, ...
Read more >Demystifying React Native Stack Traces in Production
In DEV, pass the error to the standard ExceptionsManager ... The JS stack traces in Production are not that useful by default.
Read more >failed to initialize react-native-reanimated library - You.com
module.exports = function(api) { api.cache(true); return { presets: ... 'React/RCTBridge.h' file not found on Xcode Installing MS AppCenter in an ejected ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
This library has nothing to do with LogBox, nor ExceptionsManager. Make sure to use “react-native” Jest preset and mock the native module if necessary. Looks like ExceptionsManager is already mocked, but
handleException
is not there: https://github.com/facebook/react-native/blob/master/jest/setup.js#L42Ah somehow I hallucinated that 🙂 thanks for the info!!