-
Notifications
You must be signed in to change notification settings - Fork 24.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
iOS crash, only release from testflight or archive build #23465
Comments
It looks like you are using an older version of React Native. Please update to the latest release, v0.58 and verify if the issue still exists. The "Resolution: Old Version" label will be removed automatically once you edit your original post with the results of running |
Just to set expectations, we rarely track individual crashes in this repository, with the exception of reports where there are clear repro steps (i.e. a small sample project that shows the crash). As it happens, debugging individual crashes in any particular application is something that is very likely out of reach for any one in this repo other than yourself. |
@hramos Thanks for the reply, but in my description I outlined a possible issue on the ModuleRegistry class, I was hoping to get some discussion around that point. |
@hramos just to let you know: I'm running into a similar issue with iPhone XS MAX iOS 12.1.4 in a project that is unrelated to @mtostenson's project. Using https://github.com/f111fei/react-native-unity-view as well.
|
Thanks for the additional detail. I'm re-opening due to the original author's desire to discuss potential causes, but I retain my stance that investigating individual crashes in different projects is unlikely to be fruitful in this repository. I'm unsubscribing from notifications for this thread. |
We are experiencing a similar crash in 0.57.8 that also seems attributable to memory management in some fashion. Approximately 4% of our app launches experience the crash below within 2 seconds of the app booting.
@mtostenson you mentioned you had some success working around this issue - would it be possible for you to post the fix you put into place? We'd love to give it a try in our project.
|
@lklepner the fix @mtostenson mentioned above is captured in the first screenshot in this comment. Hope this helps. |
Many thanks @JanOwiesniak, I'll give that a try. |
I also encountered the same crash, positioning the problem is to get the resource is not RAMBundle. I am suspecting that the test environment problem when the device is coordinated Crashed: com.apple.root.user-interactive-qos |
After tracking the code, it has been confirmed that [RCTBridge invalidate] is called in the main thread, while [RCTCxxBridge executeApplicationScript:] loads resources in the dispatch_get_global_queue--QOS_CLASS_USER_INTERACTIVE thread, and the user quickly initializes and unregisters (or reloads) the RCTBridge. Causes the callback_ of Instance::loadScriptFromString in Instance.cpp to be released and still crashed. Quote the original code and annotations of Daxie /** |
我缓存了 RCTBridge,没有移除bridge,线上还报奔溃,定位到是 callback_->incrementPendingJSCalls();方法奔溃,callback_是一个Null,callback_只有初始化没有移除方法, |
@lklepner did this work? |
It didn't seem to work. (We work together) |
I got it (partially!). Actually "release" implementation of UI_USER_INTERFACE_IDIOM() in swift project crashes the app. However, still I have no clue why our app store app (objective c language based) does NOT crash. My only guess is that it's a glitch in UI_USER_INTERFACE_IDIOM() API implementation with some language specific coding (swift vs objective c) by Apple. Anyways, I would replace all UI_USER_INTERFACE_IDIOM() with UIDevice(). userInterfaceIdiom. I hope this helps someone! |
Hey there, it looks like there has been no activity on this issue recently. Has the issue been fixed, or does it still require the community's attention? This issue may be closed if no further activity occurs. You may also label this issue as a "Discussion" or add it to the "Backlog" and I will leave it open. Thank you for your contributions. |
Closing this issue after a prolonged period of inactivity. If this issue is still present in the latest release, please feel free to create a new issue with up-to-date information. |
@amirhosein5858 i have same issue, did you find any solution? |
hi, in build setting / swift copiler - code generation / change optimization level for release to 'No Optimization' |
@amirhosein5858 It's not a good way to solve this issue. if you just close Optimization, you will package much useless codes into your ipa and release to users. And the real bug still hides in codes. |
Hello |
🐛 Bug Report
Crash on launch. Here is the relevant log:
I have been able to narrow it down to this function: ModuleRegistry::moduleNames
When the vector that is returned from this function goes out of scope and the memory is freed, the app inexplicably crashes. I have been able to work around this by adding a field to ModuleRegistry.h that stores the value returned from moduleNames, and in doing so the memory is not freed and the app continues to run as normal. I find it odd that moduleNames() returns a vector that is not stored anywhere, was this intended?
To Reproduce
I'm using React Native 0.57.3, but the latest version does not have any changes in the ModuleRegistry class where the issue seems to be happening. I am using a third party library that includes a custom RCTBridgeModule. It behaves normally until we do a beta on testflight or a local archive.
Expected Behavior
I would not expect the app to crash on launch.
Environment
React Native Environment Info:
System:
OS: macOS High Sierra 10.13.6
CPU: (8) x64 Intel(R) Core(TM) i7-4980HQ CPU @ 2.80GHz
Memory: 50.11 MB / 16.00 GB
Shell: 3.2.57 - /bin/bash
Binaries:
Node: 10.14.1 - ~/.nvm/versions/node/v10.14.1/bin/node
npm: 6.4.1 - ~/.nvm/versions/node/v10.14.1/bin/npm
Watchman: 4.6.0 - /usr/local/bin/watchman
SDKs:
iOS SDK:
Platforms: iOS 12.0, macOS 10.14, tvOS 12.0, watchOS 5.0
Android SDK:
API Levels: 23, 25, 26, 27, 28
Build Tools: 23.0.1, 25.0.2, 25.0.3, 26.0.1, 26.0.2, 26.0.3, 27.0.1, 27.0.3, 28.0.3
System Images: android-27 | Google Play Intel x86 Atom
IDEs:
Android Studio: 3.2 AI-181.5540.7.32.5056338
Xcode: 10.0/10A255 - /usr/bin/xcodebuild
npmPackages:
react: 16.6.0-alpha.8af6728 => 16.6.0-alpha.8af6728
react-native: 0.57.3 => 0.57.3
npmGlobalPackages:
react-native-ar: 2.0.0-test19
react-native-cli: 2.0.1
react-native-unity-view: 1.3.2
solidarity-react-native: 2.0.2
The text was updated successfully, but these errors were encountered: