This class is not a key value compatible with the encoding for the key attribute.

I suspect some code is trying to use my FooterArchiveView , similar to an NSDictionary , so I tried to use breakpoints to find a bottleneck, but my breakpoints send me to wild goose hunting in system files like UINibDecoderDecodeObjectForValue . What should I do?

 2012-03-08 08:35:55.417 JOM App[44161:207] Uncaught exception: [<FooterArchiveView 0x9b27770> setValue:forUndefinedKey:]: this class is not key value coding-compliant for the key featured. 2012-03-08 08:35:55.420 JOM App[44161:207] Stack trace: ( 0 CoreFoundation 0x0169c06e __exceptionPreprocess + 206 1 libobjc.A.dylib 0x01c50d0a objc_exception_throw + 44 2 CoreFoundation 0x0169bf11 -[NSException raise] + 17 3 Foundation 0x00f89032 -[NSObject(NSKeyValueCoding) setValue:forUndefinedKey:] + 282 4 Foundation 0x00efaf7b _NSSetUsingKeyValueSetter + 136 5 Foundation 0x00efaeeb -[NSObject(NSKeyValueCoding) setValue:forKey:] + 287 6 UIKit 0x00628268 -[UIView(CALayerDelegate) setValue:forKey:] + 168 7 Foundation 0x00f15d60 -[NSObject(NSKeyValueCoding) setValue:forKeyPath:] + 393 8 UIKit 0x0080891a -[UIRuntimeOutletConnection connect] + 106 9 CoreFoundation 0x0169de1a -[NSObject performSelector:] + 58 10 CoreFoundation 0x01607821 -[NSArray makeObjectsPerformSelector:] + 273 11 UIKit 0x0080746e -[UINib instantiateWithOwner:options:] + 1178 12 UIKit 0x00809010 -[NSBundle(UINSBundleAdditions) loadNibNamed:owner:options:] + 157 13 JOM App 0x0000e9ca -[ContentView setContent:] + 1258 14 JOM App 0x0000c906 -[NavigationView devotionsTUI:] + 390 15 CoreFoundation 0x0169dec9 -[NSObject performSelector:withObject:withObject:] + 73 16 UIKit 0x005ec5c2 -[UIApplication sendAction:to:from:forEvent:] + 96 17 UIKit 0x005ec55a -[UIApplication sendAction:toTarget:fromSender:forEvent:] + 61 18 UIKit 0x00691b76 -[UIControl sendAction:to:forEvent:] + 66 19 UIKit 0x0069203f -[UIControl(Internal) _sendActionsForEvents:withEvent:] + 503 20 UIKit 0x006912fe -[UIControl touchesEnded:withEvent:] + 549 21 UIKit 0x00611a30 -[UIWindow _sendTouchesForEvent:] + 513 22 UIKit 0x00611c56 -[UIWindow sendEvent:] + 273 23 UIKit 0x005f8384 -[UIApplication sendEvent:] + 464 24 UIKit 0x005ebaa9 _UIApplicationHandleEvent + 8196 25 GraphicsServices 0x02589fa9 PurpleEventCallback + 1274 26 CoreFoundation 0x016701c5 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE1_PERFORM_FUNCTION__ + 53 27 CoreFoundation 0x015d5022 __CFRunLoopDoSource1 + 146 28 CoreFoundation 0x015d390a __CFRunLoopRun + 2218 29 CoreFoundation 0x015d2db4 CFRunLoopRunSpecific + 212 30 CoreFoundation 0x015d2ccb CFRunLoopRunInMode + 123 31 GraphicsServices 0x02588879 GSEventRunModal + 207 32 GraphicsServices 0x0258893e GSEventRun + 114 33 UIKit 0x005e9a9b UIApplicationMain + 1175 34 JOM App 0x000027d2 main + 178 35 JOM App 0x00002715 start + 53 36 ??? 0x00000001 0x0 + 1 ) 
+4
source share
1 answer

"This class is not the key to encode for the selected key." means that the class is trying to set the property on the object by encoding with keywords, only to find that it cannot. This most often happens when you identify the outlet, plug it into the tip, then remove the output from your code, leaving the dangling connection in the tip. When the deserializer is deserialized, it tries to connect the socket using key encoding and you see the error above.

+15
source

Source: https://habr.com/ru/post/1400411/


All Articles