Qiita Teams that are logged in
You are not logged in to any team

Log in to Qiita Team
Community
OrganizationEventAdvent CalendarQiitadon (β)
Service
Qiita JobsQiita ZineQiita Blog
7
Help us understand the problem. What are the problem?

More than 5 years have passed since last update.

@reikubonaga

iOS8ではconstraintにuser define runtime attributeに値を設定しても落ちないが、iOS7では落ちる

間違えてstroyboardのuser define runtime attributeに値を追加してしまったときに、気づきにくいバグになってしまう。
エラーのメモがてら記録しておきます。

2014-10-20 18:37:10.180 app-qa[44937:70b] *** Terminating app due to uncaught exception 'NSUnknownKeyException', reason: '[<NSLayoutConstraint 0x7ff527238d90> setValue:forUndefinedKey:]: this class is not key value coding-compliant for the key keyPath.'
*** First throw call stack:
(
    0   CoreFoundation                      0x000000010c1e1795 __exceptionPreprocess + 165
    1   libobjc.A.dylib                     0x000000010bf3d991 objc_exception_throw + 43
    2   CoreFoundation                      0x000000010c265e69 -[NSException raise] + 9
    3   Foundation                          0x0000000109fb503a -[NSObject(NSKeyValueCoding) setValue:forKey:] + 259
    4   CoreFoundation                      0x000000010c1dd700 -[NSArray makeObjectsPerformSelector:] + 224
    5   UIKit                               0x000000010b0ea1a5 -[UINib instantiateWithOwner:options:] + 1112
    6   UIKit                               0x000000010af8c4a1 -[UIViewController _loadViewFromNibNamed:bundle:] + 245
    7   UIKit                               0x000000010af8cade -[UIViewController loadView] + 112
    8   UIKit                               0x000000010af8cdfd -[UIViewController loadViewIfRequired] + 75
    9   UIKit                               0x000000010af8d1bd -[UIViewController view] + 29
    10  UIKit                               0x000000010afa37a5 -[UINavigationController _startCustomTransition:] + 628
    11  UIKit                               0x000000010afae9b5 -[UINavigationController _startDeferredTransitionIfNeeded:] + 401
    12  UIKit                               0x000000010afaf4f8 -[UINavigationController __viewWillLayoutSubviews] + 43
    13  UIKit                               0x000000010b0c37e1 -[UILayoutContainerView layoutSubviews] + 202
    14  UIKit                               0x000000010aefcb27 -[UIView(CALayerDelegate) layoutSublayersOfLayer:] + 354
    15  QuartzCore                          0x000000010abcfa22 -[CALayer layoutSublayers] + 151
    16  QuartzCore                          0x000000010abc4589 _ZN2CA5Layer16layout_if_neededEPNS_11TransactionE + 363
    17  QuartzCore                          0x000000010abc440a _ZN2CA5Layer28layout_and_display_if_neededEPNS_11TransactionE + 24
    18  QuartzCore                          0x000000010ab39694 _ZN2CA7Context18commit_transactionEPNS_11TransactionE + 252
    19  QuartzCore                          0x000000010ab3a70c _ZN2CA11Transaction6commitEv + 394
    20  QuartzCore                          0x000000010ab3ad79 _ZN2CA11Transaction17observer_callbackEP19__CFRunLoopObservermPv + 89
    21  CoreFoundation                      0x000000010c1acff7 __CFRUNLOOP_IS_CALLING_OUT_TO_AN_OBSERVER_CALLBACK_FUNCTION__ + 23
    22  CoreFoundation                      0x000000010c1acf67 __CFRunLoopDoObservers + 391
    23  CoreFoundation                      0x000000010c18c6d2 __CFRunLoopRun + 946
    24  CoreFoundation                      0x000000010c18bf33 CFRunLoopRunSpecific + 467
    25  GraphicsServices                    0x000000010e6e23a0 GSEventRunModal + 161
    26  UIKit                               0x000000010aea1043 UIApplicationMain + 1010
    27  app-qa                              0x000000010807413b main + 155
    28  libdyld.dylib                       0x000000010c7a05fd start + 1
    29  ???                                 0x0000000000000001 0x0 + 1
)
libc++abi.dylib: terminating with uncaught exception of type NSException
Why not register and get more from Qiita?
  1. We will deliver articles that match you
    By following users and tags, you can catch up information on technical fields that you are interested in as a whole
  2. you can read useful information later efficiently
    By "stocking" the articles you like, you can search right away
7
Help us understand the problem. What are the problem?