react-native icon indicating copy to clipboard operation
react-native copied to clipboard

Exception when reloading

Open adamtwiss opened this issue 10 years ago • 4 comments

I am having problems with frequent crashes on reloads in my app. Not sure if this is something I've done (don't think I've done anything wrong). My app is a basic tabbed app, with some navigator logic to determine logged in state and some login screens at the front.

Running fairly recent versions of everything:

  • IOS 9 simulator, on an Iphone6 (simulator running v9.2 13C75)
  • It generally happens for me around the times of refreshes (e.g. hitting apple-R in emulator). Not 100% recreateable, seems to be 'racey'. Happens perhaps every 30 mins to me during active development.
  • React Native v0.1.7
  • Host is MacOS 10.11.3 Beta (15D9c)
  • Xcode Version 7.2 (7C68)

Stack dump follows (XXXXX is where I've removed my client's name)

2016-01-07 15:13:24.566 XXXXXXX[62697:9092283] Unbalanced calls to begin/end appearance transitions for <RCTWrapperViewController: 0x7fd055c72a30>.
2016-01-07 15:13:24.568 XXXXXXX[62697:9092283] *** Assertion failure in -[RCTNavigator wrapperViewController:didMoveToNavigationController:](), /Users/adam/Documents/XXXXXXX/XXXXXXXXX/node_modules/react-native/React/Views/RCTNavigator.m:562
2016-01-07 15:13:24.573 XXXXXXXXX[62697:9092283] *** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'If JS doesn't have the lock there should never be any pending transitions'
*** First throw call stack:
(
    0   CoreFoundation                      0x000000010ba5fe65 __exceptionPreprocess + 165
    1   libobjc.A.dylib                     0x000000010ac63deb objc_exception_throw + 48
    2   CoreFoundation                      0x000000010ba5fcca +[NSException raise:format:arguments:] + 106
    3   Foundation                          0x000000010a8b05a2 -[NSAssertionHandler handleFailureInFunction:file:lineNumber:description:] + 169
    4   XXXXXXX                          0x000000010a5b90f8 -[RCTNavigator wrapperViewController:didMoveToNavigationController:] + 888
    5   XXXXXXX                         0x000000010a56a866 -[RCTWrapperViewController didMoveToParentViewController:] + 230
    6   UIKit                               0x000000010d52ca85 -[UIViewController _setViewAppearState:isAnimating:] + 1146
    7   UIKit                               0x000000010d52d18f -[UIViewController __viewDidDisappear:] + 136
    8   UIKit                               0x000000010d566000 -[UINavigationController viewDidDisappear:] + 262
    9   UIKit                               0x000000010d52c859 -[UIViewController _setViewAppearState:isAnimating:] + 590
    10  UIKit                               0x000000010d52cd52 __52-[UIViewController _setViewAppearState:isAnimating:]_block_invoke + 166
    11  CoreFoundation                      0x000000010b9a170d __53-[__NSArrayI enumerateObjectsWithOptions:usingBlock:]_block_invoke + 77
    12  CoreFoundation                      0x000000010b9a15b6 -[__NSArrayI enumerateObjectsWithOptions:usingBlock:] + 166
    13  UIKit                               0x000000010d52cb31 -[UIViewController _setViewAppearState:isAnimating:] + 1318
    14  UIKit                               0x000000010d52d18f -[UIViewController __viewDidDisappear:] + 136
    15  UIKit                               0x000000010d580f98 -[UITabBarController viewDidDisappear:] + 109
    16  UIKit                               0x000000010d52c859 -[UIViewController _setViewAppearState:isAnimating:] + 590
    17  UIKit                               0x000000010d52d18f -[UIViewController __viewDidDisappear:] + 136
    18  UIKit                               0x000000010d52f805 __64-[UIViewController viewDidMoveToWindow:shouldAppearOrDisappear:]_block_invoke1266 + 42
    19  UIKit                               0x000000010d52d9d2 -[UIViewController _executeAfterAppearanceBlock] + 86
    20  UIKit                               0x000000010d39c5de _runAfterCACommitDeferredBlocks + 633
    21  UIKit                               0x000000010d3afc01 _cleanUpAfterCAFlushAndRunDeferredBlocks + 95
    22  UIKit                               0x000000010d3bbaf3 _afterCACommitHandler + 90
    23  CoreFoundation                      0x000000010b98b367 __CFRUNLOOP_IS_CALLING_OUT_TO_AN_OBSERVER_CALLBACK_FUNCTION__ + 23
    24  CoreFoundation                      0x000000010b98b2d7 __CFRunLoopDoObservers + 391
    25  CoreFoundation                      0x000000010b980f2b __CFRunLoopRun + 1147
    26  CoreFoundation                      0x000000010b980828 CFRunLoopRunSpecific + 488
    27  GraphicsServices                    0x000000010f7f8ad2 GSEventRunModal + 161
    28  UIKit                               0x000000010d390610 UIApplicationMain + 171
    29  XXXXXXXX                            0x000000010a52278f main + 111
    30  libdyld.dylib                       0x000000010f04a92d start + 1
    31  ???                                 0x0000000000000001 0x0 + 1
)
libc++abi.dylib: terminating with uncaught exception of type NSException

Xcode debugger kicks in in UAApplicationMain on this line:

    return UIApplicationMain(argc, argv, nil, NSStringFromClass([AppDelegate class]));

adamtwiss avatar Jan 07 '16 15:01 adamtwiss

Hey adamtwiss, thanks for reporting this issue!

React Native, as you've probably heard, is getting really popular and truth is we're getting a bit overwhelmed by the activity surrounding it. There are just too many issues for us to manage properly.

  • If you don't know how to do something or something is not working as you expect but not sure it's a bug, please ask on StackOverflow with the tag react-native or for more real time interactions, ask on Discord in the #react-native channel.
  • If this is a feature request or a bug that you would like to be fixed, please report it on Product Pains. It has a ranking feature that lets us focus on the most important issues the community is experiencing.
  • We welcome clear issues and PRs that are ready for in-depth discussion. Please provide screenshots where appropriate and always mention the version of React Native you're using. Thank you for your contributions!

facebook-github-bot avatar Jan 07 '16 15:01 facebook-github-bot

@facebook-github-bot stack-overflow

christopherdro avatar Mar 20 '16 16:03 christopherdro

Hey @adamtwiss and thanks for posting this! @christopherdro tells me this issue looks like a question that would be best asked on StackOverflow. StackOverflow is amazing for Q&A: it has a reputation system, voting, the ability to mark a question as answered. Because of the reputation system it is likely the community will see and answer your question there. This also helps us use the GitHub bug tracker for bugs only. Will close this as this is really a question that should be asked on SO.

facebook-github-bot avatar Mar 20 '16 16:03 facebook-github-bot

I also get this problem,but I don't find any solution....

askday avatar Apr 28 '16 10:04 askday