Freeze & Crash when remote debug enabled RN@0.42.0-rc.1
See original GitHub issueDescription
I tried to update an existing project to RN@0.42.0-rc.1 and noticed that the app freezes and crashes when I try to dispatch a redux action open a modal. I then went and tried to isolate the issue and found out it crashes only when remote debug is enabled, which makes me think it might not be related to redux. This is the last error in console:
Error: Attempted to remove more RCTKeyboardObserver listeners than added
Reproduction
- clone and install patrikholcak/react-native-remote-bug
- Run iOS simulator, toggle remote debug on
- Click
Toggle modal
— first click will freeze the app and the second one will crash it
Solution
No idea.
Additional Information
- React Native version: 0.42.0-rc.1
- Platform: iOS
- Operating System: MacOS
Issue Analytics
- State:
- Created 7 years ago
- Reactions:18
- Comments:39 (12 by maintainers)
Top Results From Across the Web
Visual Studio Remote Debugger Freezes and Crashes ...
We are seeing an issue when using the remote debugger attached to service host. Whenever debugging asynchronous code, using step into or step...
Read more >React Native Android crashes on enabling debug mode
The same react native codebase, turning on dubug mode on ios is working fine, but on Android it always crash when debug mode...
Read more >Remote debugger freezes application : IDEA-204154 - YouTrack
Have java application running outside of IntelliJ (localhost is fine) · Connect to that JVM with a remote debugger. · Place a breakpoint...
Read more >Cloud Applications Studio (Pilot) freezes while Debugging
While debugging in the SAP Cloud Applications Studio (Pilot), you notice that the program freezes. After some time the program is force quit....
Read more >Chapter 10. Kernel Debugging | FreeBSD Documentation Portal
FreeBSD Kernel Debugging. ... On FreeBSD 9.0-RELEASE and later versions, bsdinstall will ask whether crash dumps should be enabled on the ...
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 Free
Top 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
Oooookay guys, so I have it figured out… sort of.
The elevation changes I introduced to
YellowBox
cause iOS apps to hang when remote debugging is enabled and a warning is logged.So my changes do not effect the
Modal
component directly, it’s just thatModal
is logging the warning"Calling of '[-RCTUIManager setFrame:forView]' which is deprecated"
which in turn brings out the bug introduced by myYellowBox
changes in iOS.So the actual bug we’re observing is what @alphasp posted.
In summary: Android + no remote debugging = OK Android + remote debugging = OK iOS + no remote debugging = OK iOS + remote debugging = HANGS
Interestingly, if I change
elevation: Number.MAX_VALUE
toNumber.MAX_SAFE_INTEGER
the bug dissappears. So maybe there’s some sort of overflow occurring on iOS, I’m not sure.I don’t really have the time to get to the actual root of the issue, so I just propose any of these changes:
or 2)
or 3)
Preferences? Or does someone want to get to the ACTUAL root of the issue?
I think this issue is also related to #12368 and appears when using Modal on IOS, in a specific context, in debug mode.
I do not use redux, my app actually uses NavigationExperimental (the root component of the display is a NavigationCardStack) and when I display a Modal on IOS in Debug Mode, the render() function freezes and the modal is never displayed. On Android, the very same code works fine in both Normal and Debug Mode.
This freeze happens in 0.42.0-rc3, but NOT in 0.41.2.
I couldn’t create a minimal app that reproduces the bug, as just adding a modal to the default app created after an init’ does not trigger the issue. There is something more, but not sure what makes the issue appear.