This is the error:
* Terminating app due to uncaught exception 'NSRangeException', reason: '* -[__NSArrayI objectAtIndex:]: index 18446744073709551615 beyond bounds [0 .. 1]'
*** First throw call stack:
(
0 CoreFoundation 0x0000000104b09f45 __exceptionPreprocess + 165
1 libobjc.A.dylib 0x0000000104edbdeb objc_exception_throw + 48
2 CoreFoundation 0x00000001049f8b14 -[__NSArrayI objectAtIndex:] + 164
3 MyApp 0x000000010234ae4b -[AppManager homePage] + 203
4 MyApp 0x000000010234a437 -[AppManager init] + 503
5 MyApp 0x000000010234a222 __28+[AppManager sharedInstance]_block_invoke + 50
6 libdispatch.dylib 0x00000001061da49b _dispatch_client_callout + 8
7 libdispatch.dylib 0x00000001061c5e28 dispatch_once_f + 543
8 MyApp 0x000000010234a1cb +[AppManager sharedInstance] + 107
9 MyApp 0x000000010238494b -[SplashViewController viewDidLoad] + 379
10 UIKit 0x0000000103652cc4 -[UIViewController loadViewIfRequired] + 1198
11 UIKit 0x00000001036970ee -[UINavigationController _layoutViewController:] + 54
12 UIKit 0x00000001036979c2 -[UINavigationController _updateScrollViewFromViewController:toViewController:] + 462
13 UIKit 0x0000000103697b34 -[UINavigationController _startTransition:fromViewController:toViewController:] + 126
14 UIKit 0x0000000103698d8d -[UINavigationController _startDeferredTransitionIfNeeded:] + 890
15 UIKit 0x0000000103699cea -[UINavigationController __viewWillLayoutSubviews] + 57
16 UIKit 0x000000010383fc85 -[UILayoutContainerView layoutSubviews] + 248
17 UIKit 0x0000000103574e40 -[UIView(CALayerDelegate) layoutSublayersOfLayer:] + 710
18 QuartzCore 0x000000010324059a -[CALayer layoutSublayers] + 146
19 QuartzCore 0x0000000103234e70 _ZN2CA5Layer16layout_if_neededEPNS_11TransactionE + 366
20 QuartzCore 0x0000000103234cee _ZN2CA5Layer28layout_and_display_if_neededEPNS_11TransactionE + 24
21 QuartzCore 0x0000000103229475 _ZN2CA7Context18commit_transactionEPNS_11TransactionE + 277
22 QuartzCore 0x0000000103256c0a _ZN2CA11Transaction6commitEv + 486
23 QuartzCore 0x000000010325737c _ZN2CA11Transaction17observer_callbackEP19__CFRunLoopObservermPv + 92
24 CoreFoundation 0x0000000104a35947 __CFRUNLOOP_IS_CALLING_OUT_TO_AN_OBSERVER_CALLBACK_FUNCTION__ + 23
25 CoreFoundation 0x0000000104a358b7 __CFRunLoopDoObservers + 391
26 CoreFoundation 0x0000000104a2ae2c CFRunLoopRunSpecific + 524
27 UIKit 0x00000001034bb4f5 -[UIApplication _run] + 402
28 UIKit 0x00000001034c030d UIApplicationMain + 171
29 MyApp 0x000000010239b63f main + 111
30 libdyld.dylib 0x000000010620e92d start + 1
31 ??? 0x0000000000000001 0x0 + 1
)
libc++abi.dylib: terminating with uncaught exception of type NSException
I'm not accessing any object inside NSArray which leads to following error, however certainly my app giving me this error.
The error is in your homePage method, which you can see here:
2 CoreFoundation ... -[__NSArrayI objectAtIndex:] + 164
3 MyApp ... -[AppManager homePage] + 203 <----THIS CALLS objectAtIndex: ABOVE
According to the error message, it is trying to access the index 18446744073709551615. This is the value of NSNotFound, which means you are probably handling NSNotFound incorrectly!
Issue with -[AppManager homePage] method kindly check if there is any array accessed there
Related
So i was doing a tutorial from Sinch! on how to Fetch and Call Contacts,
Well it loads up the Contacts just fine.
The problem is that whenever I select a Contact to call, the app crashes and Xcode shows this error on the console.
Can anyone help me with that?
inchAppToPhoneTutorial[1143:42160] *** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: 'Parameter 'applicationKey' is invalid (was '')'
*** First throw call stack:
(
0 CoreFoundation 0x000000010a70634b __exceptionPreprocess + 171
1 libobjc.A.dylib 0x000000010a08821e objc_exception_throw + 48
2 SinchAppToPhoneTutorial 0x0000000108cca77b SINCallOrderByStartTimeComparator + 66724
3 SinchAppToPhoneTutorial 0x0000000108cb1c6b _ZN6rebrtc13OfflineInvite6encodeERKS0_PhmPm + 4418449
4 SinchAppToPhoneTutorial 0x0000000108cc4d45 SINCallOrderByStartTimeComparator + 43630
5 SinchAppToPhoneTutorial 0x0000000108cc496c SINCallOrderByStartTimeComparator + 42645
6 SinchAppToPhoneTutorial 0x00000001088268e9 -[DetailViewController initSinchClient] + 89
7 SinchAppToPhoneTutorial 0x0000000108825e8a -[DetailViewController viewDidLoad] + 234
8 UIKit 0x000000010accb06d -[UIViewController loadViewIfRequired] + 1258
9 UIKit 0x000000010acd14d6 -[UIViewController __viewWillAppear:] + 118
10 UIKit 0x000000010acfc393 -[UINavigationController _startCustomTransition:] + 1290
11 UIKit 0x000000010ad0d008 -[UINavigationController _startDeferredTransitionIfNeeded:] + 697
12 UIKit 0x000000010ad0e19b -[UINavigationController __viewWillLayoutSubviews] + 58
13 UIKit 0x000000010af051b7 -[UILayoutContainerView layoutSubviews] + 223
14 UIKit 0x000000010abee344 -[UIView(CALayerDelegate) layoutSublayersOfLayer:] + 1237
15 QuartzCore 0x000000010e03bcdc -[CALayer layoutSublayers] + 146
16 QuartzCore 0x000000010e02f7a0 _ZN2CA5Layer16layout_if_neededEPNS_11TransactionE + 366
17 QuartzCore 0x000000010e02f61e _ZN2CA5Layer28layout_and_display_if_neededEPNS_11TransactionE + 24
18 QuartzCore 0x000000010dfbd62c _ZN2CA7Context18commit_transactionEPNS_11TransactionE + 280
19 QuartzCore 0x000000010dfea713 _ZN2CA11Transaction6commitEv + 475
20 UIKit 0x000000010ab54878 _afterCACommitHandler + 346
21 CoreFoundation 0x000000010a6aae17 __CFRUNLOOP_IS_CALLING_OUT_TO_AN_OBSERVER_CALLBACK_FUNCTION__ + 23
22 CoreFoundation 0x000000010a6aad87 __CFRunLoopDoObservers + 391
23 CoreFoundation 0x000000010a68fb9e __CFRunLoopRun + 1198
24 CoreFoundation 0x000000010a68f494 CFRunLoopRunSpecific + 420
25 GraphicsServices 0x000000010e959a6f GSEventRunModal + 161
26 UIKit 0x000000010ab29f34 UIApplicationMain + 159
27 SinchAppToPhoneTutorial 0x00000001088257bf main + 111
28 libdyld.dylib 0x000000010c4fe68d start + 1
)
libc++abi.dylib: terminating with uncaught exception of type NSException
(lldb)
It says what happened at the very top
inchAppToPhoneTutorial[1143:42160] *** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: 'Parameter 'applicationKey' is invalid (was '')'
So figure out where you're calling something that utilizes an applicationKey and figure out why it's blank :)
I am relatively new to Swift and iOS in general. When I create a segue from a button to another view, I get a nasty error message (below). Can someone help me decipher this?
2016-04-17 16:25:49.133 FoodPin[9322:676896] *** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: '-[UITableViewController loadView] instantiated view controller with identifier "UIViewController-u9a-Ka-ctP" from storyboard "Main", but didn't get a UITableView.'
*** First throw call stack:
(
0 CoreFoundation 0x0000000102d58d85 __exceptionPreprocess + 165
1 libobjc.A.dylib 0x0000000104afcdeb objc_exception_throw + 48
2 CoreFoundation 0x0000000102d58cbd +[NSException raise:format:] + 205
3 UIKit 0x000000010396e4e2 -[UITableViewController loadView] + 638
4 UIKit 0x000000010371b560 -[UIViewController loadViewIfRequired] + 138
5 UIKit 0x000000010372193b -[UIViewController __viewWillAppear:] + 120
6 UIKit 0x0000000103751750 -[UINavigationController _startCustomTransition:] + 1203
7 UIKit 0x0000000103761b9b -[UINavigationController _startDeferredTransitionIfNeeded:] + 712
8 UIKit 0x0000000103762d0b -[UINavigationController __viewWillLayoutSubviews] + 57
9 UIKit 0x0000000103911503 -[UILayoutContainerView layoutSubviews] + 248
10 UIKit 0x000000010363b980 -[UIView(CALayerDelegate) layoutSublayersOfLayer:] + 703
11 QuartzCore 0x0000000108006c00 -[CALayer layoutSublayers] + 146
12 QuartzCore 0x0000000107ffb08e _ZN2CA5Layer16layout_if_neededEPNS_11TransactionE + 366
13 QuartzCore 0x0000000107ffaf0c _ZN2CA5Layer28layout_and_display_if_neededEPNS_11TransactionE + 24
14 QuartzCore 0x0000000107fef3c9 _ZN2CA7Context18commit_transactionEPNS_11TransactionE + 277
15 QuartzCore 0x000000010801d086 _ZN2CA11Transaction6commitEv + 486
16 QuartzCore 0x000000010801d7f8 _ZN2CA11Transaction17observer_callbackEP19__CFRunLoopObservermPv + 92
17 CoreFoundation 0x0000000102c7dc37 __CFRUNLOOP_IS_CALLING_OUT_TO_AN_OBSERVER_CALLBACK_FUNCTION__ + 23
18 CoreFoundation 0x0000000102c7dba7 __CFRunLoopDoObservers + 391
19 CoreFoundation 0x0000000102c737fb __CFRunLoopRun + 1147
20 CoreFoundation 0x0000000102c730f8 CFRunLoopRunSpecific + 488
21 GraphicsServices 0x00000001073eead2 GSEventRunModal + 161
22 UIKit 0x0000000103580f09 UIApplicationMain + 171
23 FoodPin 0x0000000102b589f2 main + 114
24 libdyld.dylib 0x00000001055c092d start + 1
)
libc++abi.dylib: terminating with uncaught exception of type NSException
(lldb)
I'm developing an app that uses SQLITE and works perfectly on Iphone 6plus simulator but crash on Iphone6 simulator and also on Iphone5. I'm not sure what's the problem. Can anyone help me with that?
This is the debug error that I'm getting from Xcode
*** Terminating app due to uncaught exception 'NSRangeException', reason:
*** -[__NSArrayM objectAtIndex:]: index 9223372036854775807 beyond bounds [0 .. 10]'
*** First throw call stack:
(
0 CoreFoundation 0x000000010492ae65 __exceptionPreprocess + 165
1 libobjc.A.dylib 0x00000001043a3deb objc_exception_throw + 48
2 CoreFoundation 0x000000010480e404 -[__NSArrayM objectAtIndex:] + 212
3 ILFCalc 0x0000000103d85cf8 -[EditInfoViewController loadInfoToEdit] + 424
4 ILFCalc 0x0000000103d83f76 -[EditInfoViewController viewDidLoad] + 1174
5 UIKit 0x0000000104e6df98 -[UIViewController loadViewIfRequired] + 1198
6 UIKit 0x0000000104e73f4f -[UIViewController __viewWillAppear:] + 120
7 UIKit 0x0000000104ea3e44 -[UINavigationController _startCustomTransition:] + 1203
8 UIKit 0x0000000104eb423f -[UINavigationController _startDeferredTransitionIfNeeded:] + 712
9 UIKit 0x0000000104eb53af -[UINavigationController __viewWillLayoutSubviews] + 57
10 UIKit 0x000000010505bff7 -[UILayoutContainerView layoutSubviews] + 248
11 UIKit 0x0000000104d8e4a3 -[UIView(CALayerDelegate) layoutSublayersOfLayer:] + 703
12 QuartzCore 0x000000010874559a -[CALayer layoutSublayers] + 146
13 QuartzCore 0x0000000108739e70 _ZN2CA5Layer16layout_if_neededEPNS_11TransactionE + 366
14 QuartzCore 0x0000000108739cee _ZN2CA5Layer28layout_and_display_if_neededEPNS_11TransactionE + 24
15 QuartzCore 0x000000010872e475 _ZN2CA7Context18commit_transactionEPNS_11TransactionE + 277
16 QuartzCore 0x000000010875bc0a _ZN2CA11Transaction6commitEv + 486
17 QuartzCore 0x000000010875c37c _ZN2CA11Transaction17observer_callbackEP19__CFRunLoopObservermPv + 92
18 CoreFoundation 0x0000000104856367 __CFRUNLOOP_IS_CALLING_OUT_TO_AN_OBSERVER_CALLBACK_FUNCTION__ + 23
19 CoreFoundation 0x00000001048562d7 __CFRunLoopDoObservers + 391
20 CoreFoundation 0x000000010484bf2b __CFRunLoopRun + 1147
21 CoreFoundation 0x000000010484b828 CFRunLoopRunSpecific + 488
22 GraphicsServices 0x0000000107fd2ad2 GSEventRunModal + 161
23 UIKit 0x0000000104cd7610 UIApplicationMain + 171
24 ILFCalc 0x0000000103d898af main + 111
25 libdyld.dylib 0x000000010631a92d start + 1
26 ??? 0x0000000000000001 0x0 + 1
)
libc++abi.dylib: terminating with uncaught exception of type NSException
(lldb)
Code:
NSString *Query=[NSString stringWithFormat:#"select *from peopleinfm where peopleinfmID=%d",TextEdit];
NSArray *Results=[[NSArray alloc]initWithArray:[DBManger loadDataFromDB:Query]];
self.FirstnameText.text=[[Results objectAtIndex:1]objectAtIndex:[self.DBManger.ColumnArray indexOfObject:#"firstname"]];
self.LastnameText.text=[[Results objectAtIndex:1]objectAtIndex:[self.DBManger.ColumnArray indexOfObject:#"lastname"]];
self.AgeText.text=[[Results objectAtIndex:1]objectAtIndex:[self.DBManger.ColumnArray indexOfObject:#"age"]];
Logs:
2016-02-12 19:03:36.068 SampleFMDB[9641:762577] no such table: peopleinfm
2016-02-12 19:03:36.077 SampleFMDB[9641:762577] _UIConstraintBasedLayoutLogUnsatisfiable is OFF
2016-02-12 19:03:37.934 SampleFMDB[9641:762577] no such table: peopleinfm
2016-02-12 19:03:37.978 SampleFMDB[9641:762577] *** Terminating app due to uncaught exception 'NSRangeException', reason: '*** -[__NSArray0 objectAtIndex:]: index 1 beyond bounds for empty NSArray'
*** First throw call stack:
(
0 CoreFoundation 0x00b23a94 __exceptionPreprocess + 180
1 libobjc.A.dylib 0x005e2e02 objc_exception_throw + 50
2 CoreFoundation 0x00aca4a0 __CFArrayGetTypeID_block_invoke + 0
3 SampleFMDB 0x00010003 -[AddViewController loadInfoToEdit] + 291
4 SampleFMDB 0x0000f9bc -[AddViewController viewDidLoad] + 396
5 UIKit 0x01070d74 -[UIViewController _sendViewDidLoadWithAppearanceProxyObjectTaggingEnabled] + 44
6 UIKit 0x010758c2 -[UIViewController loadViewIfRequired] + 1556
7 UIKit 0x0107bf0e -[UIViewController __viewWillAppear:] + 114
8 UIKit 0x0109ecf0 -[UIViewController(UIContainerViewControllerProtectedMethods) beginAppearanceTransition:animated:] + 202
9 UIKit 0x010b0d63 -[UINavigationController _startCustomTransition:] + 1375
10 UIKit 0x010c1c0b -[UINavigationController _startDeferredTransitionIfNeeded:] + 801
11 UIKit 0x010c2d05 -[UINavigationController __viewWillLayoutSubviews] + 68
12 UIKit 0x0128cd9f -[UILayoutContainerView layoutSubviews] + 252
13 UIKit 0x00f7916b -[UIView(CALayerDelegate) layoutSublayersOfLayer:] + 813
14 libobjc.A.dylib 0x005f7059 -[NSObject performSelector:withObject:] + 70
15 QuartzCore 0x048ae60c -[CALayer layoutSublayers] + 144
16 QuartzCore 0x048a228e _ZN2CA5Layer16layout_if_neededEPNS_11TransactionE + 388
17 QuartzCore 0x048a20f2 _ZN2CA5Layer28layout_and_display_if_neededEPNS_11TransactionE + 26
18 QuartzCore 0x04894c2b _ZN2CA7Context18commit_transactionEPNS_11TransactionE + 317
19 QuartzCore 0x048c8c23 _ZN2CA11Transaction6commitEv + 589
20 QuartzCore 0x048ca484 _ZN2CA11Transaction17flush_transactionEv + 50
21 UIKit 0x00eadb55 _UIApplicationHandleEventQueue + 7921
22 CoreFoundation 0x00a3de7f __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION__ + 15
23 CoreFoundation 0x00a33b0b __CFRunLoopDoSources0 + 523
24 CoreFoundation 0x00a32f28 __CFRunLoopRun + 1032
25 CoreFoundation 0x00a32866 CFRunLoopRunSpecific + 470
26 CoreFoundation 0x00a3267b CFRunLoopRunInMode + 123
27 GraphicsServices 0x04148664 GSEventRunModal + 192
28 GraphicsServices 0x041484a1 GSEventRun + 104
29 UIKit 0x00eb3cc1 UIApplicationMain + 160
30 SampleFMDB 0x000108ea main + 138
31 libdyld.dylib 0x030f6a21 start + 1
)
libc++abi.dylib: terminating with uncaught exception of type NSException
I was recently trying to create a hidden button called signupComplete, and suddenly now I get this error everytime I try to run the app. here is the error message I recieve in the console:
*** Terminating app due to uncaught exception 'NSUnknownKeyException', reason: '[<SignupViewController 0x10a3519f0> setValue:forUndefinedKey:]: this class is not key value coding-compliant for the key signupComplete.'
Im not sure why I am getting this. I even went back and removed anything that had to do with the signupComplete button, but I still keep receiving this error.
*** First throw call stack: (
0 CoreFoundation 0x0000000102846495 __exceptionPreprocess + 165
1 libobjc.A.dylib 0x00000001025a599e objc_exception_throw + 43
2 CoreFoundation 0x00000001028ca919 -[NSException raise] + 9
3 Foundation 0x0000000102186530 -[NSObject(NSKeyValueCoding) setValue:forKey:] + 259
4 CoreFoundation 0x0000000102842400 -[NSArray makeObjectsPerformSelector:] + 224
5 UIKit 0x00000001013ad8a6 -[UINib instantiateWithOwner:options:] + 1131
6 UIKit 0x0000000101247b0c -[UIViewController _loadViewFromNibNamed:bundle:] + 245
7 UIKit 0x0000000101248149 -[UIViewController loadView] + 112
8 UIKit 0x00000001012483b7 -[UIViewController loadViewIfRequired] + 75
9 UIKit 0x0000000101248777 -[UIViewController view] + 29
10 UIKit 0x000000010125f2c5 -[UINavigationController _startCustomTransition:] + 628
11 UIKit 0x000000010126a6f5 -[UINavigationController _startDeferredTransitionIfNeeded:] + 401
12 UIKit 0x000000010126b238 -[UINavigationController __viewWillLayoutSubviews] + 43
13 UIKit 0x0000000101385895 -[UILayoutContainerView layoutSubviews] + 202
14 UIKit 0x00000001011b2993 -[UIView(CALayerDelegate) layoutSublayersOfLayer:] + 354
15 QuartzCore 0x00000001004d5802 -[CALayer layoutSublayers] + 151
16 QuartzCore 0x00000001004ca369 _ZN2CA5Layer16layout_if_neededEPNS_11TransactionE + 363
17 QuartzCore 0x00000001004ca1ea _ZN2CA5Layer28layout_and_display_if_neededEPNS_11TransactionE + 24
18 QuartzCore 0x000000010043dfb8 _ZN2CA7Context18commit_transactionEPNS_11TransactionE + 252
19 QuartzCore 0x000000010043f030 _ZN2CA11Transaction6commitEv + 394
20 UIKit 0x0000000101151024 _UIApplicationHandleEventQueue + 10914
21 CoreFoundation 0x00000001027d5d21 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION__ + 17
22 CoreFoundation 0x00000001027d55f2 __CFRunLoopDoSources0 + 242
23 CoreFoundation 0x00000001027f146f __CFRunLoopRun + 767
24 CoreFoundation 0x00000001027f0d83 CFRunLoopRunSpecific + 467
25 GraphicsServices 0x000000010459ef04 GSEventRunModal + 161
26 UIKit 0x0000000101152e33 UIApplicationMain + 1010
27 PickPiic 0x0000000100002853 main + 115
28 libdyld.dylib 0x00000001031855fd start + 1
29 ??? 0x0000000000000001 0x0 + 1
)
libc++abi.dylib: terminating with uncaught exception of type NSException
(lldb)