Monotouch Application fatal error - iphone

I am trying to understand the reason my app crashes, randomly it seems, when trying to present a view.
The button click code:
if ( d.rootNavigationController.RespondsToSelector(
new MonoTouch.ObjCRuntime.Selector("presentViewController:animated:completion:")))
{
d.rootNavigationController.PresentViewController(childBroswer, true,null);
}
else
{
d.rootNavigationController.PresentModalViewController(childBroswer, true);
}
This is the stack trace:
at MonoTouch.UIKit.UIApplication.Main (string[],string,string) [0x0004c] in /Developer/MonoTouch/Source/monotouch/src/UIKit/UIApplication.cs:38
at appname.Application.Main (string[]) [0x00000] in /Users/us/Projects/appname/appname/Main.cs:17
at (wrapper runtime-invoke) object.runtime_invoke_dynamic (intptr,intptr,intptr,intptr) <0xffffffff>
Native stacktrace:
0 appname 0x00a81ba9 mono_handle_native_sigsegv + 244
1 appname 0x00a48015 mono_sigsegv_signal_handler + 172
2 libsystem_c.dylib 0x35df3e93 _sigtramp + 42
3 UIKit 0x33f820a5 <redacted> + 72
4 UIKit 0x33f82057 <redacted> + 30
5 UIKit 0x33f82035 <redacted> + 44
6 UIKit 0x33f818eb <redacted> + 502
7 UIKit 0x33f81de1 <redacted> + 488
8 UIKit 0x33ea0421 <redacted> + 5768
9 CoreFoundation 0x3ad3a6cd <redacted> + 20
10 CoreFoundation 0x3ad389c1 <redacted> + 276
11 CoreFoundation 0x3ad38d17 <redacted> + 742
12 CoreFoundation 0x3acabebd CFRunLoopRunSpecific + 356
13 CoreFoundation 0x3acabd49 CFRunLoopRunInMode + 104
14 GraphicsServices 0x390792eb GSEventRunModal + 74
15 UIKit 0x33eeb2f9 UIApplicationMain + 1120
16 appname 0x0006f618 wrapper_managed_to_native_MonoTouch_UIKit_UIApplication_UIApplicationMain_int_string___intptr_intptr + 240
17 appname 0x009bdb20 appname_Application_Main_string__ + 152
18 appname 0x0068664c wrapper_runtime_invoke_object_runtime_invoke_dynamic_intptr_intptr_intptr_intptr + 200
19 appname 0x00a4962f mono_jit_runtime_invoke + 1054
20 appname 0x00aa5df3 mono_runtime_invoke + 90
21 appname 0x00aa88d7 mono_runtime_exec_main + 306
22 appname 0x00aabb5b mono_runtime_run_main + 482
23 appname 0x00a5c133 mono_jit_exec + 94
24 appname 0x00ae9e3c main + 2220
25 appname 0x00002028 start + 40
Got a SIGSEGV while executing native code. This usually indicates
a fatal error in the mono runtime or one of the native libraries
used by your application.
Any ideas what is the error?
Thanks!

Related

NSInvalidArgumentException', reason: '-[__SwiftValue set]

Scenario
I have a SwiftUI app that has been working perfectly fine.
I upgrade Xcode to 13.2.1 and I'm able to launch the application but when I navigate to a certain part of the application I'm getting this error on device and during SwiftUI preview.
'NSInvalidArgumentException', reason: '-[__SwiftValue set]: unrecognized selector sent to instance 0x600001bd9590'
Feedback / Assistance
Can anyone provide instructions / steps to debug this?
How can I find out what is instance 0x600001bd9590 and who is setting the NSInvalidArgumentException
*** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '-[__SwiftValue set]: unrecognized selector sent to instance 0x600001bd9590'
dyld4 config: DYLD_ROOT_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Library/Developer/CoreSimulator/Profiles/Runtimes/iOS.simruntime/Contents/Resources/RuntimeRoot DYLD_LIBRARY_PATH=/Users/m1/Library/Developer/Xcode/DerivedData/NT-dfyuqrdtadtqdkaxajldzwimkhru/Build/Intermediates.noindex/Previews/NT/Products/Debug-iphonesimulator DYLD_INSERT_LIBRARIES=/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Library/Developer/CoreSimulator/Profiles/Runtimes/iOS.simruntime/Contents/Resources/RuntimeRoot//System/Library/PrivateFrameworks/PreviewsInjection.framework/PreviewsInjection DYLD_FRAMEWORK_PATH=/Users/m1/Library/Developer/Xcode/DerivedData/NT-dfyuqrdtadtqdkaxajldzwimkhru/Build/Intermediates.noindex/Previews/NT/Products/Debug-iphonesimulator
abort() called
Last Exception Backtrace:
0 CoreFoundation 0x1803e1174 __exceptionPreprocess + 216
1 libobjc.A.dylib 0x180193384 objc_exception_throw + 56
2 CoreFoundation 0x1803f0530 +[NSObject(NSObject) instanceMethodSignatureForSelector:] + 0
3 CoreFoundation 0x1803e53fc ___forwarding___ + 1408
4 CoreFoundation 0x1803e743c _CF_forwarding_prep_0 + 92
5 UIFoundation 0x18410cc7c -[NSCoreTypesetter _NSFastDrawString:length:attributes:paragraphStyle:typesetterBehavior:lineBreakMode:rect:padding:graphicsContext:baselineRendering:usesFontLeading:usesScreenFont:scrollable:syncAlignment:mirrored:boundingRectPointer:baselineOffsetPointer:drawingContext:] + 3820
6 UIFoundation 0x18410d6c0 -[NSCoreTypesetter _stringDrawingCoreTextEngineWithOriginalString:rect:padding:graphicsContext:forceClipping:attributes:stringDrawingOptions:drawingContext:stringDrawingInterface:] + 1200
7 UIFoundation 0x184107bf0 __NSStringDrawingEngine + 1480
8 UIFoundation 0x184108b24 -[NSAttributedString(NSExtendedStringDrawing) drawWithRect:options:context:] + 128
9 UIKitCore 0x18524a2b4 -[UILabel _drawTextInRect:baselineCalculationOnly:] + 3100
10 UIKitCore 0x18524abb8 -[UILabel _drawTextInRect:] + 248
11 UIKitCore 0x185249330 -[UILabel drawTextInRect:] + 536
12 UIKitCore 0x185300714 -[UIView(CALayerDelegate) drawLayer:inContext:] + 536
13 QuartzCore 0x1883ad940 CABackingStoreUpdate_ + 192
14 QuartzCore 0x1884e0078 invocation function for block in CA::Layer::display_() + 52
15 QuartzCore 0x1884d66dc -[CALayer _display] + 1688
16 QuartzCore 0x1884e8ce4 CA::Layer::layout_and_display_if_needed(CA::Transaction*) + 408
17 QuartzCore 0x18843c04c CA::Context::commit_transaction(CA::Transaction*, double, double*) + 516
18 QuartzCore 0x188467860 CA::Transaction::commit() + 684
19 UIKitCore 0x184dc48f4 _afterCACommitHandler + 104
20 CoreFoundation 0x18034ef9c __CFRUNLOOP_IS_CALLING_OUT_TO_AN_OBSERVER_CALLBACK_FUNCTION__ + 32
21 CoreFoundation 0x180349724 __CFRunLoopDoObservers + 556
22 CoreFoundation 0x180349c84 __CFRunLoopRun + 976
23 CoreFoundation 0x1803493a8 CFRunLoopRunSpecific + 572
24 GraphicsServices 0x18c03c5ec GSEventRunModal + 160
25 UIKitCore 0x184d937ac -[UIApplication _run] + 992
26 UIKitCore 0x184d982e8 UIApplicationMain + 112
27 SwiftUI 0x1b99bc7f4 closure #1 in KitRendererCommon(_:) + 160
28 SwiftUI 0x1b99bc750 runApp<A>(_:) + 164
29 SwiftUI 0x1b94124f4 static App.main() + 80
30 NT 0x102d46c24 static NTApp.$main() + 100
31 NT 0x102d46d38 main + 76
32 dyld_sim 0x10368dca0 start_sim + 20
33 dyld 0x1033d50f4 start + 520
34 ??? 0x4c15800000000000 ???
Thread 0 Crashed:: Dispatch queue: com.apple.main-thread
0 libsystem_kernel.dylib 0x1c997ca60 __pthread_kill + 8
1 libsystem_pthread.dylib 0x1c99ce380 pthread_kill + 256
2 libsystem_c.dylib 0x1800fe3d8 abort + 120
3 libc++abi.dylib 0x18022de94 abort_message + 128
4 libc++abi.dylib 0x18021fc98 demangling_terminate_handler() + 296
5 libobjc.A.dylib 0x180176e84 _objc_terminate() + 124
6 libc++abi.dylib 0x18022d358 std::__terminate(void (*)()) + 16
7 libc++abi.dylib 0x18022fd98 __cxa_rethrow + 144
8 libobjc.A.dylib 0x1801934d4 objc_exception_rethrow + 40
9 CoreFoundation 0x180349494 CFRunLoopRunSpecific + 808
10 GraphicsServices 0x18c03c5ec GSEventRunModal + 160
11 UIKitCore 0x184d937ac -[UIApplication _run] + 992
12 UIKitCore 0x184d982e8 UIApplicationMain + 112
13 SwiftUI 0x1b99bc7f4 closure #1 in KitRendererCommon(_:) + 160
14 SwiftUI 0x1b99bc750 runApp<A>(_:) + 164
15 SwiftUI 0x1b94124f4 static App.main() + 80
16 NT 0x102d46c24 static NTApp.$main() + 100 (NTApp.swift:10)
17 NT 0x102d46d38 main + 76
18 dyld_sim 0x10368dca0 start_sim + 20
19 dyld 0x1033d50f4 start + 520

How do I get my Xamarin app running on an iOS device?

Can anyone help me?
I'm developing a Xamarin Forms app in Visual Studio 2022 on a Windows PC. I have VS attached to a MacinCloud Mac and an iPhone connected to the Windows PC.
My app deploys and starts up on the iPhone but when I go to login it crashes.
The line of code it is crashing on is making a call to HttpClient.PostAsync to call back to our API to authenticate.
The error and crash dump are below.
Any ideas?
Thanks,
Paul.
Foundation.MonoTouchException
Message=Objective-C exception thrown. Name: NSMallocException Reason: Failed to grow buffer
Native stack trace:
0 CoreFoundation 0x0000000180a35060 B2D21CFD-378C-36D5-BAF7-3F70599CFEFC + 626784
1 libobjc.A.dylib 0x00000001990a9f54 objc_exception_throw + 60
2 CoreFoundation 0x0000000180b42af0 B2D21CFD-378C-36D5-BAF7-3F70599CFEFC + 1731312
3 CoreFoundation 0x0000000180b3addc B2D21CFD-378C-36D5-BAF7-3F70599CFEFC + 1699292
4 CoreFoundation 0x00000001809cf28c __CFSafelyReallocate + 72
5 Foundation 0x00000001821f6a48 D59C6975-5AF2-37BC-93BE-43B80B4293A5 + 232008
6 Foundation 0x00000001821f26d4 D59C6975-5AF2-37BC-93BE-43B80B4293A5 + 214740
7 Xamarin.PreBuilt.iOS 0x00000001024e9c54 do_icall + 328
8 Xamarin.PreBuilt.iOS 0x00000001024e82e4 do_icall_wrapper + 296
9 Xamarin.PreBuilt.iOS 0x00000001024df1d8 interp_exec_method_full + 2740
10 Xamarin.PreBuilt.iOS 0x00000001024dd768 interp_runtime_invoke + 336
11 Xamarin.PreBuilt.iOS 0x000000010234ae70 mono_jit_runtime_invoke + 900
12 Xamarin.PreBuilt.iOS 0x00000001023f9188 mono_runtime_try_invoke + 156
13 Xamarin.PreBuilt.iOS 0x00000001023faddc mono_runtime_invoke + 100
14 Xamarin.PreBuilt.iOS 0x00000001022613e0 _ZL31native_to_managed_trampoline_11P11objc_objectP13objc_selectorPP11_MonoMethodj + 244
15 Xamarin.PreBuilt.iOS 0x00000001022a7db8 -[UIKit_UIControlEventProxy BridgeSelector] + 44
16 UIKitCore 0x000000018330abf0 8388EB03-002B-3B35-A78A-6A022894292E + 5016560
17 UIKitCore 0x0000000183436a4c 8388EB03-002B-3B35-A78A-6A022894292E + 6244940
18 UIKitCore 0x00000001831b22c8 8388EB03-002B-3B35-A78A-6A022894292E + 3605192
19 UIKitCore 0x000000018324eae0 8388EB03-002B-3B35-A78A-6A022894292E + 4246240
20 UIKitCore 0x00000001834e17c0 8388EB03-002B-3B35-A78A-6A022894292E + 6944704
21 UIKitCore 0x0000000182fa6d40 8388EB03-002B-3B35-A78A-6A022894292E + 1461568
22 UIKitCore 0x0000000182fd98c8 8388EB03-002B-3B35-A78A-6A022894292E + 1669320
23 UIKitCore 0x0000000182fe6a68 8388EB03-002B-3B35-A78A-6A022894292E + 1722984
24 UIKitCore 0x0000000183196318 8388EB03-002B-3B35-A78A-6A022894292E + 3490584
25 UIKitCore 0x0000000182fb9c30 8388EB03-002B-3B35-A78A-6A022894292E + 1539120
26 UIKitCore 0x0000000182faea1c 8388EB03-002B-3B35-A78A-6A022894292E + 1493532
27 UIKitCore 0x0000000182fb3ec8 8388EB03-002B-3B35-A78A-6A022894292E + 1515208
28 CoreFoundation 0x0000000180a57020 B2D21CFD-378C-36D5-BAF7-3F70599CFEFC + 765984
29 CoreFoundation 0x0000000180a67ce0 B2D21CFD-378C-36D5-BAF7-3F70599CFEFC + 834784
30 CoreFoundation 0x00000001809a1fe8 B2D21CFD-378C-36D5-BAF7-3F70599CFEFC + 24552
31 CoreFoundation 0x00000001809a77f4 B2D21CFD-378C-36D5-BAF7-3F70599CFEFC + 47092
32 CoreFoundation 0x00000001809bb3b8 CFRunLoopRunSpecific + 600
33 GraphicsServices 0x000000019c34b38c GSEventRunModal + 164
34 UIKitCore 0x000000018335b6a8 8388EB03-002B-3B35-A78A-6A022894292E + 5346984
35 UIKitCore 0x00000001830da7f4 UIApplicationMain + 2092
36 Xamarin.PreBuilt.iOS 0x00000001024e9bb0 do_icall + 164
37 Xamarin.PreBuilt.iOS 0x00000001024e82e4 do_icall_wrapper + 296
38 Xamarin.PreBuilt.iOS 0x00000001024df1d8 interp_exec_method_full + 2740
39 Xamarin.PreBuilt.iOS 0x00000001024dd768 interp_runtime_invoke + 336
40 Xamarin.PreBuilt.iOS 0x000000010234ae70 mono_jit_runtime_invoke + 900
41 Xamarin.PreBuilt.iOS 0x00000001023f7984 mono_runtime_invoke_checked + 148
42 Xamarin.PreBuilt.iOS 0x00000001023fe000 mono_runtime_try_invoke_array + 1272
43 Xamarin.PreBuilt.iOS 0x00000001023a74f0 ves_icall_InternalInvoke + 1036
44 Xamarin.PreBuilt.iOS 0x00000001023b7780 ves_icall_InternalInvoke_raw + 108
45 Xamarin.PreBuilt.iOS 0x00000001024e9bb0 do_icall + 164
46 Xamarin.PreBuilt.iOS 0x00000001024e82e4 do_icall_wrapper + 296
47 Xamarin.PreBuilt.iOS 0x00000001024df1d8 interp_exec_method_full + 2740
48 Xamarin.PreBuilt.iOS 0x00000001024dd768 interp_runtime_invoke + 336
49 Xamarin.PreBuilt.iOS 0x000000010234ae70 mono_jit_runtime_invoke + 900
50 Xamarin.PreBuilt.iOS 0x00000001023f7984 mono_runtime_invoke_checked + 148
51 Xamarin.PreBuilt.iOS 0x00000001023fcbf8 mono_runtime_exec_main_checked + 128
52 Xamarin.PreBuilt.iOS 0x000000010232f850 mono_jit_exec + 376
53 Xamarin.PreBuilt.iOS 0x00000001024db834 xamarin_main + 1944
54 Xamarin.PreBuilt.iOS 0x00000001022f74f4 main + 76
55 dyld 0x0000000102e71a24 start + 520
Source=Xamarin.iOS
StackTrace:
at ObjCRuntime.Runtime.ThrowNSException (System.IntPtr ns_exception) [0x00000] in /Users/builder/azdo/_work/1/s/xamarin-macios/src/ObjCRuntime/Runtime.cs:449
at ObjCRuntime.Runtime.throw_ns_exception (System.IntPtr exc) [0x00000] in /Users/builder/azdo/_work/1/s/xamarin-macios/runtime/Delegates.generated.cs:392
at (wrapper native-to-managed) ObjCRuntime.Runtime.throw_ns_exception(intptr)
I have managed to solve this issue by creating a handler and passing it in to the constructor of my Http client.
var handler = new HttpClientHandler();
var httpClient = new HttpClient(handler);
I thought I had already tried this solution earlier to no avail but I found a second place that was creating the client and implementing it there as well solved the issue.

macCatalyst crash on UIScene in macOS 11 (Big Sur) [closed]

Closed. This question needs debugging details. It is not currently accepting answers.
Edit the question to include desired behavior, a specific problem or error, and the shortest code necessary to reproduce the problem. This will help others answer the question.
Closed 2 years ago.
Improve this question
I have a macCatalyst app that works perfectly on macOS 10.14, however on upgrading to macOS 11 (Big Sur) both I and my users are complaining that the app crashes on launch. I get an error message "Parameter was not of class UIScene" - do macCatalyst apps now require the use of scenes?
On further inspection, I see the following:
2020-11-28 01:48:40.327810+0000 AppName [13691:435322] *** Assertion failure in -[_UISceneMacHelperUtilities sceneIdentifierForUIScene:], _UISceneMacHelperUtilities.m:83
2020-11-28 01:48:40.336334+0000 AppName[13691:435322] [General] An uncaught exception was raised
2020-11-28 01:48:40.336423+0000 AppName[13691:435322] [General] Parameter was not of class UIScene.
2020-11-28 01:48:40.336545+0000 AppName[13691:435322] [General] (
0 CoreFoundation 0x00007fff204ae6af __exceptionPreprocess + 242
1 libobjc.A.dylib 0x00007fff201e63c9 objc_exception_throw + 48
2 CoreFoundation 0x00007fff204d7512 +[NSException raise:format:arguments:] + 88
3 Foundation 0x00007fff212906c9 -[NSAssertionHandler handleFailureInMethod:object:file:lineNumber:description:] + 191
4 UIKitCore 0x00007fff44a7b2c6 -[_UISceneMacHelperUtilities sceneIdentifierForUIScene:] + 195
5 UIKitMacHelper 0x00007fff34045f74 __46-[UINSApplicationDelegate _setupKeyWindowSync]_block_invoke + 393
6 Foundation 0x00007fff21192d6b -[__NSObserver _doit:] + 287
7 CoreFoundation 0x00007fff20429fdc __CFNOTIFICATIONCENTER_IS_CALLING_OUT_TO_AN_OBSERVER__ + 12
8 CoreFoundation 0x00007fff204c589b ___CFXRegistrationPost_block_invoke + 49
9 CoreFoundation 0x00007fff204c580f _CFXRegistrationPost + 454
10 CoreFoundation 0x00007fff203fabce _CFXNotificationPost + 723
11 Foundation 0x00007fff21166abe -[NSNotificationCenter postNotificationName:object:userInfo:] + 59
12 UIKitCore 0x00007fff44376779 -[UIWindow _makeKeyWindowIgnoringOldKeyWindow:] + 567
13 AppName 0x00000001013fe0c0 $s25AppName13SceneDelegateC5scene_13willConnectTo7optionsySo7UISceneC_So0K7SessionCSo0K17ConnectionOptionsCtF + 1520
14 AppName 0x00000001013feaa6 $s25AppName13SceneDelegateC5scene_13willConnectTo7optionsySo7UISceneC_So0K7SessionCSo0K17ConnectionOptionsCtFTo + 118
15 UIKitCore 0x00007fff44221a31 +[UIScene _sceneForFBSScene:create:withSession:connectionOptions:] + 1463
16 UIKitCore 0x00007fff4421ffb1 -[UIApplication _connectUISceneFromFBSScene:transitionContext:] + 1109
17 UIKitCore 0x00007fff4421ecfe -[UIApplication workspace:didCreateScene:withTransitionContext:completion:] + 299
18 UIKitCore 0x00007fff4421eb49 -[UIApplicationSceneClientAgent scene:didInitializeWithEvent:completion:] + 358
19 FrontBoardServices 0x00007fff317e7312 -[FBSScene _callOutQueue_agent_didCreateWithTransitionContext:completion:] + 391
20 FrontBoardServices 0x00007fff318045df __94-[FBSWorkspaceScenesClient createWithSceneID:groupID:parameters:transitionContext:completion:]_block_invoke.176 + 102
21 FrontBoardServices 0x00007fff317d60c1 -[FBSWorkspace _calloutQueue_executeCalloutFromSource:withBlock:] + 209
22 FrontBoardServices 0x00007fff318042b7 __94-[FBSWorkspaceScenesClient createWithSceneID:groupID:parameters:transitionContext:completion:]_block_invoke + 354
23 libdispatch.dylib 0x00000001040c50b0 _dispatch_client_callout + 8
24 libdispatch.dylib 0x00000001040c8927 _dispatch_block_invoke_direct + 286
25 FrontBoardServices 0x00007fff317d5fd8 __FBSSERIALQUEUE_IS_CALLING_OUT_TO_A_BLOCK__ + 30
26 FrontBoardServices 0x00007fff3181e1c3 -[FBSSerialQueue _targetQueue_performNextIfPossible] + 433
27 FrontBoardServices 0x00007fff317d5fa0 -[FBSSerialQueue _performNextFromRunLoopSource] + 22
28 CoreFoundation 0x00007fff204349fc __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION__ + 17
29 CoreFoundation 0x00007fff20434964 __CFRunLoopDoSource0 + 180
30 CoreFoundation 0x00007fff204346df __CFRunLoopDoSources0 + 248
31 CoreFoundation 0x00007fff20433111 __CFRunLoopRun + 890
32 CoreFoundation 0x00007fff204326be CFRunLoopRunSpecific + 563
33 HIToolbox 0x00007fff2869efd0 RunCurrentEventLoopInMode + 292
34 HIToolbox 0x00007fff2869edcc ReceiveNextEventCommon + 709
35 HIToolbox 0x00007fff2869eaef _BlockUntilNextEventMatchingListInModeWithFilter + 64
36 AppKit 0x00007fff22c4bf85 _DPSNextEvent + 883
37 AppKit 0x00007fff22c4a74b -[NSApplication(NSEvent) _nextEventMatchingEventMask:untilDate:inMode:dequeue:] + 1366
38 AppKit 0x00007fff22c3cbda -[NSApplication run] + 586
39 AppKit 0x00007fff22c10f31 NSApplicationMain + 816
40 AppKit 0x00007fff22f0744d _NSApplicationMainWithInfoDictionary + 16
41 UIKitMacHelper 0x00007fff3403332e UINSApplicationMain + 1418
42 UIKitCore 0x00007fff44202e30 UIApplicationMain + 144
43 AppName 0x00000001014da40b main + 75
44 libdyld.dylib 0x00007fff20357631 start + 1
)
2020-11-28 01:48:40.337802+0000 AppName[13691:435322] *** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'Parameter was not of class UIScene.'
*** First throw call stack:
(
0 CoreFoundation 0x00007fff204ae6af __exceptionPreprocess + 242
1 libobjc.A.dylib 0x00007fff201e63c9 objc_exception_throw + 48
2 CoreFoundation 0x00007fff204d7512 +[NSException raise:format:arguments:] + 88
3 Foundation 0x00007fff212906c9 -[NSAssertionHandler handleFailureInMethod:object:file:lineNumber:description:] + 191
4 UIKitCore 0x00007fff44a7b2c6 -[_UISceneMacHelperUtilities sceneIdentifierForUIScene:] + 195
5 UIKitMacHelper 0x00007fff34045f74 __46-[UINSApplicationDelegate _setupKeyWindowSync]_block_invoke + 393
6 Foundation 0x00007fff21192d6b -[__NSObserver _doit:] + 287
7 CoreFoundation 0x00007fff20429fdc __CFNOTIFICATIONCENTER_IS_CALLING_OUT_TO_AN_OBSERVER__ + 12
8 CoreFoundation 0x00007fff204c589b ___CFXRegistrationPost_block_invoke + 49
9 CoreFoundation 0x00007fff204c580f _CFXRegistrationPost + 454
10 CoreFoundation 0x00007fff203fabce _CFXNotificationPost + 723
11 Foundation 0x00007fff21166abe -[NSNotificationCenter postNotificationName:object:userInfo:] + 59
12 UIKitCore 0x00007fff44376779 -[UIWindow _makeKeyWindowIgnoringOldKeyWindow:] + 567
13 AppName 0x00000001013fe0c0 $s25AppName13SceneDelegateC5scene_13willConnectTo7optionsySo7UISceneC_So0K7SessionCSo0K17ConnectionOptionsCtF + 1520
14 AppName 0x00000001013feaa6 $s25AppName13SceneDelegateC5scene_13willConnectTo7optionsySo7UISceneC_So0K7SessionCSo0K17ConnectionOptionsCtFTo + 118
15 UIKitCore 0x00007fff44221a31 +[UIScene _sceneForFBSScene:create:withSession:connectionOptions:] + 1463
16 UIKitCore 0x00007fff4421ffb1 -[UIApplication _connectUISceneFromFBSScene:transitionContext:] + 1109
17 UIKitCore 0x00007fff4421ecfe -[UIApplication workspace:didCreateScene:withTransitionContext:completion:] + 299
18 UIKitCore 0x00007fff4421eb49 -[UIApplicationSceneClientAgent scene:didInitializeWithEvent:completion:] + 358
19 FrontBoardServices 0x00007fff317e7312 -[FBSScene _callOutQueue_agent_didCreateWithTransitionContext:completion:] + 391
20 FrontBoardServices 0x00007fff318045df __94-[FBSWorkspaceScenesClient createWithSceneID:groupID:parameters:transitionContext:completion:]_block_invoke.176 + 102
21 FrontBoardServices 0x00007fff317d60c1 -[FBSWorkspace _calloutQueue_executeCalloutFromSource:withBlock:] + 209
22 FrontBoardServices 0x00007fff318042b7 __94-[FBSWorkspaceScenesClient createWithSceneID:groupID:parameters:transitionContext:completion:]_block_invoke + 354
23 libdispatch.dylib 0x00000001040c50b0 _dispatch_client_callout + 8
24 libdispatch.dylib 0x00000001040c8927 _dispatch_block_invoke_direct + 286
25 FrontBoardServices 0x00007fff317d5fd8 __FBSSERIALQUEUE_IS_CALLING_OUT_TO_A_BLOCK__ + 30
26 FrontBoardServices 0x00007fff3181e1c3 -[FBSSerialQueue _targetQueue_performNextIfPossible] + 433
27 FrontBoardServices 0x00007fff317d5fa0 -[FBSSerialQueue _performNextFromRunLoopSource] + 22
28 CoreFoundation 0x00007fff204349fc __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION__ + 17
29 CoreFoundation 0x00007fff20434964 __CFRunLoopDoSource0 + 180
30 CoreFoundation 0x00007fff204346df __CFRunLoopDoSources0 + 248
31 CoreFoundation 0x00007fff20433111 __CFRunLoopRun + 890
32 CoreFoundation 0x00007fff204326be CFRunLoopRunSpecific + 563
33 HIToolbox 0x00007fff2869efd0 RunCurrentEventLoopInMode + 292
34 HIToolbox 0x00007fff2869edcc ReceiveNextEventCommon + 709
35 HIToolbox 0x00007fff2869eaef _BlockUntilNextEventMatchingListInModeWithFilter + 64
36 AppKit 0x00007fff22c4bf85 _DPSNextEvent + 883
37 AppKit 0x00007fff22c4a74b -[NSApplication(NSEvent) _nextEventMatchingEventMask:untilDate:inMode:dequeue:] + 1366
38 AppKit 0x00007fff22c3cbda -[NSApplication run] + 586
39 AppKit 0x00007fff22c10f31 NSApplicationMain + 816
40 AppKit 0x00007fff22f0744d _NSApplicationMainWithInfoDictionary + 16
41 UIKitMacHelper 0x00007fff3403332e UINSApplicationMain + 1418
42 UIKitCore 0x00007fff44202e30 UIApplicationMain + 144
43 AppName 0x00000001014da40b main + 75
44 libdyld.dylib 0x00007fff20357631 start + 1
)
libc++abi.dylib: terminating with uncaught exception of type NSException
*** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'Parameter was not of class UIScene.'
terminating with uncaught exception of type NSException

FIRMessaging client not setup

I've search for some other question/solutions here but can't fix this issue in my App. I can't figure out what is the issue. It was working properly.
When I run my app on Actual Device or on Simulator it crashes on the splash screen. Here is the crash log.
*** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'FIRMessaging client not setup.'
*** First throw call stack:
(
0 CoreFoundation 0x000000010cfd71bb __exceptionPreprocess + 331
1 libobjc.A.dylib 0x000000010c0f9735 objc_exception_throw + 48
2 CoreFoundation 0x000000010cfd6f42 +[NSException raise:format:arguments:] + 98
3 Foundation 0x0000000109abc940 -[NSAssertionHandler handleFailureInFunction:file:lineNumber:description:] + 166
4 Tarfeeh 0x0000000106e7ee9c -[FIRMessaging connectWithCompletion:] + 556
5 Tarfeeh 0x0000000106dcb573 $S7Tarfeeh11AppDelegateC12connectToFcmyyF + 579
6 Tarfeeh 0x0000000106cd900f $S7Tarfeeh11AppDelegateC11application_29didFinishLaunchingWithOptionsSbSo13UIApplicationC_SDySo0j6LaunchI3KeyaypGSgtF + 2431
7 Tarfeeh 0x0000000106cd97f4 $S7Tarfeeh11AppDelegateC11application_29didFinishLaunchingWithOptionsSbSo13UIApplicationC_SDySo0j6LaunchI3KeyaypGSgtFTo + 228
8 UIKitCore 0x000000011290ebde -[UIApplication _handleDelegateCallbacksWithOptions:isSuspended:restoreState:] + 280
9 UIKitCore 0x00000001129105cb -[UIApplication _callInitializationDelegatesForMainScene:transitionContext:] + 3979
10 UIKitCore 0x0000000112915c2f -[UIApplication _runWithMainScene:transitionContext:completion:] + 1623
11 UIKitCore 0x00000001121344e9 __111-[__UICanvasLifecycleMonitor_Compatability _scheduleFirstCommitForScene:transition:firstActivation:completion:]_block_invoke + 866
12 UIKitCore 0x000000011213d29c +[_UICanvas _enqueuePostSettingUpdateTransactionBlock:] + 153
13 UIKitCore 0x0000000112134126 -[__UICanvasLifecycleMonitor_Compatability _scheduleFirstCommitForScene:transition:firstActivation:completion:] + 233
14 UIKitCore 0x0000000112134ae0 -[__UICanvasLifecycleMonitor_Compatability activateEventsOnly:withContext:completion:] + 1085
15 UIKitCore 0x0000000112132cb5 __82-[_UIApplicationCanvas _transitionLifecycleStateWithTransitionContext:completion:]_block_invoke + 795
16 UIKitCore 0x000000011213295f -[_UIApplicationCanvas _transitionLifecycleStateWithTransitionContext:completion:] + 435
17 UIKitCore 0x0000000112137a90 __125-[_UICanvasLifecycleSettingsDiffAction performActionsForCanvas:withUpdatedScene:settingsDiff:fromSettings:transitionContext:]_block_invoke + 584
18 UIKitCore 0x000000011213880e _performActionsWithDelayForTransitionContext + 100
19 UIKitCore 0x00000001121377ef -[_UICanvasLifecycleSettingsDiffAction performActionsForCanvas:withUpdatedScene:settingsDiff:fromSettings:transitionContext:] + 221
20 UIKitCore 0x000000011213c93a -[_UICanvas scene:didUpdateWithDiff:transitionContext:completion:] + 392
21 UIKitCore 0x000000011291444e -[UIApplication workspace:didCreateScene:withTransitionContext:completion:] + 515
22 UIKitCore 0x00000001124b8d09 -[UIApplicationSceneClientAgent scene:didInitializeWithEvent:completion:] + 357
23 FrontBoardServices 0x00000001183da2da -[FBSSceneImpl _didCreateWithTransitionContext:completion:] + 448
24 FrontBoardServices 0x00000001183e5443 __56-[FBSWorkspace client:handleCreateScene:withCompletion:]_block_invoke_2 + 271
25 FrontBoardServices 0x00000001183e4b3a __40-[FBSWorkspace _performDelegateCallOut:]_block_invoke + 53
26 libdispatch.dylib 0x000000010f016602 _dispatch_client_callout + 8
27 libdispatch.dylib 0x000000010f019b78 _dispatch_block_invoke_direct + 301
28 FrontBoardServices 0x0000000118419ba8 __FBSSERIALQUEUE_IS_CALLING_OUT_TO_A_BLOCK__ + 30
29 FrontBoardServices 0x0000000118419860 -[FBSSerialQueue _performNext] + 457
30 FrontBoardServices 0x0000000118419e40 -[FBSSerialQueue _performNextFromRunLoopSource] + 45
31 CoreFoundation 0x000000010cf3c721 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION__ + 17
32 CoreFoundation 0x000000010cf3bf93 __CFRunLoopDoSources0 + 243
33 CoreFoundation 0x000000010cf3663f __CFRunLoopRun + 1263
34 CoreFoundation 0x000000010cf35e11 CFRunLoopRunSpecific + 625
35 GraphicsServices 0x00000001154a61dd GSEventRunModal + 62
36 UIKitCore 0x000000011291781d UIApplicationMain + 140
37 Tarfeeh 0x0000000106cdab44 main + 68
38 libdyld.dylib 0x000000010f08c575 start + 1
39 ??? 0x0000000000000001 0x0 + 1
)
libc++abi.dylib: terminating with uncaught exception of type NSException
I just updated my podfile and it stopped working. I can't revert back to old version.
Add FirebaseApp.configure() in Your AppDelegate when starting application.
func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?) -> Bool {
FirebaseApp.configure()
}

Crashlytics Swift: Get fatalError() message to the crashlog

I have a number of fatalError("Descriptive Error") lines in my app. I'd like to find which line has actually triggered the error.
However, I can't get such an information with Crashlytics. Here's what I got:
#0. Crashed: com.apple.main-thread
0 libswiftCore.dylib 0x10173cd24 specialized _fatalErrorMessage(_:_:file:line:flags:) + 128
1 libswiftCore.dylib 0x101561118 _ArrayBuffer._checkInoutAndNativeTypeCheckedBounds(_:wasNativeTypeChecked:) + 240
2 libswiftCore.dylib 0x10157b318 Array.subscript.getter + 112
3 AppName 0x10097d520 ClassName3.select(_:) (ClassName3.swift:61)
4 AppName 0x1008ee03c ClassName2.init(_:) (ClassName2.swift:28)
5 AppName 0x1008edca0 ClassName2.__allocating_init(_:) (ClassName2.swift:24)
6 AppName 0x1008603c4 ClassName4.makeController() (ClassName4.swift:19)
7 AppName 0x1008d6c88 ClassName.ClassName6(_:didSelect:) (ClassName.swift:108)
8 AppName 0x1008d6e04 protocol witness for ClassName6Delegate.ClassName6(_:didSelect:) in conformance ClassName (<compiler-generated>)
9 AppName 0x100855de0 ClassName6.text(card:) (ClassName6Item.swift:71)
10 AppName 0x100855f04 protocol witness for ClassName5.text(card:) in conformance ClassName6 (<compiler-generated>)
11 AppName 0x1007da8f4 ClassCell.buttonDidTap(_:) (ClassCell.swift:48)
12 AppName 0x1007da958 #objc ClassCell.buttonDidTap(_:) (<compiler-generated>)
13 UIKit 0x18d4826c8 -[UIApplication sendAction:to:from:forEvent:] + 96
14 UIKit 0x18d5a38a4 -[UIControl sendAction:to:forEvent:] + 80
15 UIKit 0x18d48877c -[UIControl _sendActionsForEvents:withEvent:] + 440
16 UIKit 0x18d5be1dc -[UIControl touchesEnded:withEvent:] + 572
17 UIKit 0x18da63dd8 _UIGestureEnvironmentSortAndSendDelayedTouches + 4340
18 UIKit 0x18da60b50 _UIGestureEnvironmentUpdate + 1236
19 UIKit 0x18d4fb540 -[UIGestureEnvironment _deliverEvent:toGestureRecognizers:usingBlock:] + 404
20 UIKit 0x18d4fb078 -[UIGestureEnvironment _updateGesturesForEvent:window:] + 276
21 UIKit 0x18d4fa8dc -[UIWindow sendEvent:] + 3132
22 UIKit 0x18d4f9238 -[UIApplication sendEvent:] + 340
23 UIKit 0x18dcdac0c __dispatchPreprocessedEventFromEventQueue + 2340
24 UIKit 0x18dcdd1b8 __handleEventQueueInternal + 4744
25 UIKit 0x18dcd6258 __handleHIDEventFetcherDrain + 152
26 CoreFoundation 0x1836fb404 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION__ + 24
27 CoreFoundation 0x1836fac2c __CFRunLoopDoSources0 + 276
28 CoreFoundation 0x1836f879c __CFRunLoopRun + 1204
29 CoreFoundation 0x183618da8 CFRunLoopRunSpecific + 552
30 GraphicsServices 0x1855fb020 GSEventRunModal + 100
31 UIKit 0x18d5f978c UIApplicationMain + 236
32 AppName 0x1008925c0 main (AppDelegate.swift:13)
33 libdyld.dylib 0x1830a9fc0 start +
4
Is there any way I can retrieve the message in specialized _fatalErrorMessage(_:_:file:line:flags:) + 128 ?