FIrebase iOS integration crash - caused by an invalid GOOGLE_APP_ID - ios

I am trying to build my Cordova app with Firebase integrated using Xcode build, but I am getting this vague error, and I can't understand what's wrong. I have placed the GoogleService-Info.plist file in the project directory, but it still fails to build. Here is the stack trace
2017-05-17 09:56:43.610 MyAppz[824:13611] *** Terminating app due to uncaught exception 'com.firebase.core',
reason: 'Configuration fails. It may be caused by an invalid GOOGLE_APP_ID in GoogleService-Info.plist
or set in the customized options.'
*** First throw call stack:
(
0 CoreFoundation 0x00000001099cdb0b __exceptionPreprocess + 171
1 libobjc.A.dylib 0x0000000109409141 objc_exception_throw + 48
2 CoreFoundation 0x0000000109a36625 +[NSException raise:format:] + 197
3 MyAppz 0x0000000107280b70 +[FIRApp addAppToAppDictionary:] + 371
4 MyAppz 0x000000010728011b +[FIRApp configureDefaultAppWithOptions:sendingNotifications:] + 285
5 MyAppz 0x000000010727fe4f +[FIRApp configure] + 302
6 MyAppz 0x000000010721c59a -[AppDelegate(FirebasePlugin) application:swizzledDidFinishLaunchingWithOptions:] + 122
7 UIKit 0x000000010a804957 -[UIApplication _handleDelegateCallbacksWithOptions:isSuspended:restoreState:] + 299
8 UIKit 0x000000010a80623c -[UIApplication _callInitializationDelegatesForMainScene:transitionContext:] + 4119
9 UIKit 0x000000010a80c584 -[UIApplication _runWithMainScene:transitionContext:completion:] + 1709
10 UIKit 0x000000010a809793 -[UIApplication workspaceDidEndTransaction:] + 182
11 FrontBoardServices 0x000000010fce15f6 __FBSSERIALQUEUE_IS_CALLING_OUT_TO_A_BLOCK__ + 24
12 FrontBoardServices 0x000000010fce146d -[FBSSerialQueue _performNext] + 186
13 FrontBoardServices 0x000000010fce17f6 -[FBSSerialQueue _performNextFromRunLoopSource] + 45
14 CoreFoundation 0x0000000109973c01 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION__ + 17
15 CoreFoundation 0x00000001099590cf __CFRunLoopDoSources0 + 527
16 CoreFoundation 0x00000001099585ff __CFRunLoopRun + 911
17 CoreFoundation 0x0000000109958016 CFRunLoopRunSpecific + 406
18 UIKit 0x000000010a80802f -[UIApplication _run] + 468
19 UIKit 0x000000010a80e0d4 UIApplicationMain + 159
20 MyAppz 0x0000000107195df1 main + 65
21 libdyld.dylib 0x000000010cc3a65d start + 1
)
libc++abi.dylib: terminating with uncaught exception of type NSException
What could be the problem, I don't know what else to show if it's needed, so please ask.

For some reason Xcode always ignored the GoogleService-Info.plist located in the project root directory, and didn't copied it in the Resources folder of the project.
I manually copied the file there, and then the app compiled and ran just fine.

In my case the problem was with the cordova copying GoogleService-Info.plist and corrupting it.
So the solution is you need to do it manually.
Just copy your GoogleService-Info.plist from your root folder then go to
platforms/ios/project-name/Resources and paste it there and then there is another Resources folder in it paste it there too.
platforms/ios/project-name/Resources/Resources
Then again try to make a build or run it in simulator and it'll be working fine.

Possibly your GoogleService-Info.plist file is corrupted.
Please redownload and replace it.
original discussion here - Firebase for Cordova
Hope this helps...

Also, when you use the below method,
FirebaseApp.configure(name:userName , options: .init(googleAppID: ConfigValues.Firebase.googleAppID, gcmSenderID: ConfigValues.Firebase.gcmSenderID))
make sure you give the proper googleAppID and gcmSenderID, to avoid the similar crash.

Please redownload GoogleService-Info.plist file from firebase and replace in your project. This solved my issue.

If you are initializing firebase like this
await Firebase.initializeApp(
name: "AppName",
options: FirebaseOptions(
apiKey: "XXXXXX_XXX3VeDOXXDXXXwR8",
authDomain: "myApp.com",
databaseURL:
"https://myapp.firebasedatabase.app",
projectId: "My_App",
storageBucket: "my-app-station.com",
messagingSenderId: "39847398285093",
appId: "1:439hiojfiojh84394f3j8j943",
measurementId: "G-4489KDJJHF94"),
);
update it to this
await Firebase.initializeApp();
No need to explicitly mention all fields as per new docs
Answer may vary for Flutter Web

Related

App crashes using Facebook Login SDK when I go to the home screen

I originally downloaded the FBSDK's version 4.10 and integrated them into my application by placing them in the frameworks folder. Realizing that these would not get updated over time, I removed them completely and tried to add them as pods to my project. The pods installed successfully, I have imported them correctly in my bridging header file, and there were no other issues. The pods update installed version 4.11 which has caused me some headache.
I am using the FBSDKLoginKit to log a user into their account and retrieve information from that. I am able to get back a dictionary with the users information just fine. I then pass this information to the next ViewController with a segue. At any point after this, if I press the home button on my iPhone or simulator, the app will crash. The error I get is
*** Terminating app due to uncaught exception 'NSInvalidArgumentException',
reason: '*** -[__NSPlaceholderDictionary initWithObjects:forKeys:count:]:
attempt to insert nil object from objects[3]'
This exception also occurs if I let the user log in through facebook, segue to the new view controller, unwind to the previous view controller, and then attempt to log in again. I have attempted to log the user out once retrieving their pertinent information on the second screen, but the error still persists.
I have seen a similar question asked where the "solution" was that the FBSDKLoginKit writes the retrieved dictionary to a variable and if the dictionary it has retrieved back has nil values, it throws this error.
Is there anything I can do to catch this before it happens? Has anyone found a work around?
Here is my output from the simulator when I press home:
*** First throw call stack:
(
0 CoreFoundation 0x0000000106f03d85 __exceptionPreprocess + 165
1 libobjc.A.dylib 0x000000010643edeb objc_exception_throw + 48
2 CoreFoundation 0x0000000106e0023e -[__NSPlaceholderDictionary initWithObjects:forKeys:count:] + 318
3 CoreFoundation 0x0000000106e125bb +[NSDictionary dictionaryWithObjects:forKeys:count:] + 59
4 APPNAME 0x0000000101607a1e -[FBSDKTimeSpentData instanceSuspend] + 622
5 APPNAME 0x000000010160766b +[FBSDKTimeSpentData suspend] + 59
6 APPNAME 0x00000001015b5986 -[FBSDKAppEvents applicationMovingFromActiveStateOrTerminating] + 262
7 CoreFoundation 0x0000000106ecdc8c __CFNOTIFICATIONCENTER_IS_CALLING_OUT_TO_AN_OBSERVER__ + 12
8 CoreFoundation 0x0000000106ecd9cb _CFXRegistrationPost + 427
9 CoreFoundation 0x0000000106ecd732 ___CFXNotificationPost_block_invoke + 50
10 CoreFoundation 0x0000000106f161e2 -[_CFXNotificationRegistrar find:object:observer:enumerator:] + 1986
11 CoreFoundation 0x0000000106dc5679 _CFXNotificationPost + 633
12 Foundation 0x000000010372ccd9 -[NSNotificationCenter postNotificationName:object:userInfo:] + 66
13 UIKit 0x0000000104a685ad -[UIApplication _deactivateForReason:notify:] + 629
14 UIKit 0x0000000104a6f1f1 __61-[UIApplication _sceneSettingsPreLifecycleEventDiffInspector]_block_invoke + 104
15 FrontBoardServices 0x0000000108f88d6c __52-[FBSSettingsDiffInspector inspectDiff:withContext:]_block_invoke27 + 213
16 Foundation 0x000000010377d5bb __NSIndexSetEnumerate + 1016
17 BaseBoard 0x000000010901ba8c -[BSSettingsDiff inspectChangesWithBlock:] + 116
18 FrontBoardServices 0x0000000108f83e4a -[FBSSettingsDiff inspectOtherChangesWithBlock:] + 92
19 FrontBoardServices 0x0000000108f88b2f -[FBSSettingsDiffInspector inspectDiff:withContext:] + 317
20 UIKit 0x0000000104a70880 __70-[UIApplication scene:didUpdateWithDiff:transitionContext:completion:]_block_invoke + 127
21 UIKit 0x0000000104a7052d -[UIApplication scene:didUpdateWithDiff:transitionContext:completion:] + 843
22 FrontBoardServices 0x0000000108f978c8 __FBSSERIALQUEUE_IS_CALLING_OUT_TO_A_BLOCK__ + 24
23 FrontBoardServices 0x0000000108f97741 -[FBSSerialQueue _performNext] + 178
24 FrontBoardServices 0x0000000108f97aca -[FBSSerialQueue _performNextFromRunLoopSource] + 45
25 CoreFoundation 0x0000000106e29301 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION__ + 17
26 CoreFoundation 0x0000000106e1f22c __CFRunLoopDoSources0 + 556
27 CoreFoundation 0x0000000106e1e6e3 __CFRunLoopRun + 867
28 CoreFoundation 0x0000000106e1e0f8 CFRunLoopRunSpecific + 488
29 GraphicsServices 0x0000000108ae7ad2 GSEventRunModal + 161
30 UIKit 0x0000000104a72f09 UIApplicationMain + 171
31 APPNAME 0x00000001013a26d2 main + 114
32 libdyld.dylib 0x0000000107b0d92d start + 1
33 ??? 0x0000000000000001 0x0 + 1
)
libc++abi.dylib: terminating with uncaught exception of type NSException
Running my code step by step I find that the error occurs during the method:
fbLoginManager.logInWithReadPermissions(permissionsNeeded, fromViewController: self) { (result, error) -> Void in
//crashes before it enters this block
//my code here
}
It crashes before I can even check the error value. I will attempt to check the values by stepping into the fbsdk methods and update
As soon as I press OK on this screen for the second time it crashes. How can I debug this? The action isn't in my app, its in the browser so I'm not sure where to go from here..
I have came across this issues recently, and i solved it by adding this piece of code in Appdelegate.m.
- (void)applicationDidBecomeActive:(UIApplication *)application {
[FBSDKAppEvents activateApp];
}
For Swift 3 version:
func applicationDidBecomeActive(_ application: UIApplication) {
FBSDKAppEvents.activateApp()
}
Update to 4.12, it fixes the issue according to their release notes:
https://developers.facebook.com/docs/ios/change-log-4.x/
The part that says:
Fixed
Fixed cases where AppEvents could crash because of missing session id.
Fixed bug in some cases where access token expiration date was the refresh date.
Although this is not necessarily a comprehensive solution, I have exhausted my debugging methods. I have removed the FBSDK's from my podfile, run pod update to remove them from the project, and reinstalled the version 4.10 FBSDK's in my frameworks folder. I will update this question after trying again when facebook releases an updated version of the FBSDK's.

Bridging an ObjC project with the SalesForce SDK causes a crash due to inability to find a category in the SF SDK

I have an iOS project called Core.proj that includes the SalesForce SDK and it is written in Objective-C. This project utilises the SF SDK and links the binary to the SF libraries. It does a bunch of stuff to help manage my implementation of SF. It is included in all my other Obj-C projects and it works absolutely fine within them.
This is the first time I am using this project with Swift (2.1). I am using iOS 9 with Xcode 7.1.1. I added the Core.xcodeproj into my Swift project. I then created an ObjC file. Xcode then asks if I want to create a bridging header. I do. I have created a bridging header called Swift-Bridging-Header.h. This enables me to access the files in Core.xcodeproj via the bridging header. For example, I can access my own version of the Salesforce Authentication Manager from the bridging header.
In my app delegate, I want to now kick off OAuth (I'm keeping this minimal here):
let sharedManager = MyAuthenticationManager.sharedManager()
let successBlock: OAuthFlowSuccessCallbackBlock = { sfAuthInfo in }
let failureBlock: OAuthFlowFailureCallbackBlock = { sfAuthInfo in }
sharedManager.loginWithCompletion(successBlock, failure: failureBlock)
Full disclosure: each block that you see here takes the SFOAuthInfo object as an argument. In order to get Swift to read this block, I had to add SFOAuthInfo.h into the copy files.
Now this all compiles fine but when I tap to login and execute the above code, I get the following error:
2015-12-04 11:53:54.879 MyApp[19108:3494140] -[UIDevice macaddress]: unrecognized selector sent to instance 0x7fcfb4903230
2015-12-04 11:53:54.890 MyApp[19108:3494140] *** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '-[UIDevice macaddress]: unrecognized selector sent to instance 0x7fcfb4903230'
*** First throw call stack:
(
0 CoreFoundation 0x000000010d6adf65 __exceptionPreprocess + 165
1 libobjc.A.dylib 0x000000010f624deb objc_exception_throw + 48
2 CoreFoundation 0x000000010d6b658d -[NSObject(NSObject) doesNotRecognizeSelector:] + 205
3 CoreFoundation 0x000000010d603f7a ___forwarding___ + 970
4 CoreFoundation 0x000000010d603b28 _CF_forwarding_prep_0 + 120
5 MyApp 0x000000010c869317 -[SFOAuthCredentials keyMacForService:] + 84
6 MyApp 0x000000010c8696b8 -[SFOAuthCredentials updateTokenEncryption] + 210
7 MyApp 0x000000010c8673ee -[SFOAuthCredentials initWithIdentifier:clientId:encrypted:] + 211
8 MyApp 0x000000010c84102c -[SFUserAccount initWithIdentifier:] + 197
9 MyApp 0x000000010c85f32d -[SFUserAccountManager createUserAccount] + 91
10 MyApp 0x000000010c831b41 -[SFAuthenticationManager loginWithCompletion:failure:account:] + 284
11 MyApp 0x000000010c831a0b -[SFAuthenticationManager loginWithCompletion:failure:] + 53
12 MyApp 0x000000010c60440c -[MyAuthenticationManager loginWithCompletion:failure:] + 124
13 MyApp 0x000000010c5dc58f _TFC18MyApp11AppDelegate5loginfS0_FT_T_ + 911
14 MyApp 0x000000010c5dfdc4 _TFC18MyApp25LandingPageViewController17loginButtonTappedfS0_FPSs9AnyObject_T_ + 68
15 MyApp 0x000000010c5dfe16 _TToFC18MyApp25LandingPageViewController17loginButtonTappedfS0_FPSs9AnyObject_T_ + 54
16 UIKit 0x000000010e1af1fa -[UIApplication sendAction:to:from:forEvent:] + 92
17 UIKit 0x000000010e313504 -[UIControl sendAction:to:forEvent:] + 67
18 UIKit 0x000000010e3137d0 -[UIControl _sendActionsForEvents:withEvent:] + 311
19 UIKit 0x000000010e312906 -[UIControl touchesEnded:withEvent:] + 601
20 UIKit 0x000000010e219aa3 -[UIWindow _sendTouchesForEvent:] + 835
21 UIKit 0x000000010e21a691 -[UIWindow sendEvent:] + 865
22 UIKit 0x000000010e1cc752 -[UIApplication sendEvent:] + 263
23 UIKit 0x000000010e1a7fcc _UIApplicationHandleEventQueue + 6693
24 CoreFoundation 0x000000010d5da0a1 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION__ + 17
25 CoreFoundation 0x000000010d5cffcc __CFRunLoopDoSources0 + 556
26 CoreFoundation 0x000000010d5cf483 __CFRunLoopRun + 867
27 CoreFoundation 0x000000010d5cee98 CFRunLoopRunSpecific + 488
28 GraphicsServices 0x0000000113e46ad2 GSEventRunModal + 161
29 UIKit 0x000000010e1ad676 UIApplicationMain + 171
30 MyApp 0x000000010c5ddd8d main + 109
31 libdyld.dylib 0x00000001107a592d start + 1
32 ??? 0x0000000000000001 0x0 + 1
)
libc++abi.dylib: terminating with uncaught exception of type NSException
The SF SDK has a category called UIDevice+SFHardware.h. Within this category there is a method called 'macaddress'. So clearly it is not correctly reading this category. But why? As you can see from the stack trace it is reading the other files in the SF SDK correctly.
I tried a number of things to get this to work. For example, this: iOS - UUID generation throwing a strange exception but with UIDevice+SFHardware.h. I tried this: https://developer.salesforce.com/forums/?id=906F00000009CBvIAM. I completely rebuilt the project again to check my working.
I shouldn't need to add this file into my bridge as this UIDevice+SFHardware.h is only ever accessed from SF SDK which sits within an ObjC project.
I must have done something wrong though. Any help would be greatly appreciated.
I just went through this issue.
In your Project > Build Settings > Other Linker Flags add:
-ObjC
-all_load
My SalesforceSDK is in my Pod project. If you're doing the same, set those flags in your SalesforceMobileSDK-iOS project. If not, wherever the Salesforce SDK is getting compiled.
It turns out this was a combination of things. Firstly, I was missing the -ObjC linker flag in BOTH the Swift project and the Objc project. Thanks DarthVadar123451 for pointing that out. But I also realised I was missing two libraries: libz.dylib and libxml2.dylib. Once added, everything worked. I hope that helps anyone running into the same issue.

Twitter Login initialization via Parse not working: Swift

[Xcode V.7.0 Beta 6, OSX El Capitan, iOS9]
I'm trying to add the Twitter login using the latest version of the Parse SDK. I've tried several ways of integrating the Twitter Login with Parse but its not working. I've added my consumerkey/secret and it says that I need to initialize PFTwitterUtils which I have done.
You must call PFTwitterUtils initializeWithConsumerKey:consumerSecret: to use PFTwitterUtils" I posted the full error below as well as my github repository.
At the moment I didn't add the ParseTwitterUtils framework because it didn't say i needed to in the QuickStart guide on Parse.com. However, when I add the module I get a linker error. When i take it out, i get the error below.
Steps I took:
At first, I was having an issue with the PFTwitterUtils module not appearing or being recognized. I built the project adding the frameworks in this link: https://www.parse.com/apps/quickstart?app_id=discounts--6#parse_data/mobile/ios/swift/existing and using the SDK here: https://www.parse.com/apps/quickstart?app_id=fblogin--81#parse_data/mobile/ios/swift/existing
(similar problem to this link: No such module 'Parse' following Parse iOS Swift Quickstart guide)
I posted the issue on github, thinking it's a bug on their end:
https://github.com/ParsePlatform/Parse-SDK-iOS-OSX/issues/407
I was advised to check the Framework Search Path to see if the module lives inside the folder the search path is directing to. It looked good, but it still didn't work so I also tried adding another path to the ParseSDK and that also didn't work.
I then took a Parse-Starter-project from another source where the PFTwitterUtils worked (my github repository is below with the new frameworks) but then I get the error I mentioned below. I'm assuming this is the better way of going about it because now the PFTwitterUtils is recognized within Xcode but not when building the project. I also checked the callback URL when making an app on twitter. I found a stack overflow question that had a problem with the callback URL. I edited that as well and it still doesn't work.
Here is the error I'm getting:
2015-10-14 13:13:18.374 ParseStarterProject[3757:390022] *** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'You must call PFTwitterUtils initializeWithConsumerKey:consumerSecret: to use PFTwitterUtils.'
*** First throw call stack:
(
0 CoreFoundation 0x000000010f9849b5 __exceptionPreprocess + 165
1 libobjc.A.dylib 0x0000000111927deb objc_exception_throw + 48
2 CoreFoundation 0x000000010f9848ed +[NSException raise:format:] + 205
3 ParseStarterProject 0x000000010eddcd7e +[PFTwitterUtils logInInBackground] + 31
4 ParseStarterProject 0x000000010eddce30 +[PFTwitterUtils logInWithBlock:] + 48
5 ParseStarterProject 0x000000010edca6b1 _TFC19ParseStarterProject14ViewController11viewDidLoadfS0_FT_T_ + 417
6 ParseStarterProject 0x000000010edca8c2 _TToFC19ParseStarterProject14ViewController11viewDidLoadfS0_FT_T_ + 34
7 UIKit 0x00000001106cbd05 -[UIViewController loadViewIfRequired] + 877
8 UIKit 0x00000001106cc054 -[UIViewController view] + 27
9 UIKit 0x00000001105ab77c -[UIWindow addRootViewControllerViewIfPossible] + 61
10 UIKit 0x00000001105abe79 -[UIWindow _setHidden:forced:] + 302
11 UIKit 0x00000001105bd6dc -[UIWindow makeKeyAndVisible] + 43
12 UIKit 0x000000011053dd13 -[UIApplication _callInitializationDelegatesForMainScene:transitionContext:] + 4003
13 UIKit 0x000000011054413d -[UIApplication _runWithMainScene:transitionContext:completion:] + 1755
14 UIKit 0x0000000110541390 -[UIApplication workspaceDidEndTransaction:] + 188
15 FrontBoardServices 0x00000001193b57ac -[FBSSerialQueue _performNext] + 192
16 FrontBoardServices 0x00000001193b5b1a -[FBSSerialQueue _performNextFromRunLoopSource] + 45
17 CoreFoundation 0x000000010f8b0b21 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION__ + 17
18 CoreFoundation 0x000000010f8a6a4c __CFRunLoopDoSources0 + 556
19 CoreFoundation 0x000000010f8a5f03 __CFRunLoopRun + 867
20 CoreFoundation 0x000000010f8a5918 CFRunLoopRunSpecific + 488
21 UIKit 0x0000000110540d2d -[UIApplication _run] + 402
22 UIKit 0x000000011054599e UIApplicationMain + 171
23 ParseStarterProject 0x000000010edcce6d main + 109
24 libdyld.dylib 0x0000000116bed92d start + 1
25 ??? 0x0000000000000001 0x0 + 1
)
libc++abi.dylib: terminating with uncaught exception of type NSException
(lldb)
//
In the repository the ParseTwitterUtils.framework module isn't there. But once I import it I get a linker error.
Could it be that i'm missing a Framework Search Path? When i add the Framework Search Path where the frameworks live, it doesn't change anything. Any ideas of how to add the TwitterSDK with Parse with the current SDKs I'm using?
Here's the link to my repository. https://github.com/rinyfo4/ParseStarterProject-2/tree/c512acb4360d45927f0cc5b34505d3caacae728c
Any help means a lot. Thank you in advance.
Please let me know if I can provide more information.
I solved it. As i mentioned, I went to github and was helped.
This is the answer to what was going on:
According to this guide, to enable authentication with Twitter - you need to call PFTwitterUtils.initializeWithConsumerKey:consumerSecret:
The exception is being thrown about the fact that you simply didn't initialize the twitter utils, so there is no need to unlink/remove ParseTwitterUtils from Cocoapods.
pod 'ParseTwitterUtils' and ParseTwitterUtils.framework are mutually exclusive, as they are absolutely the same thing, with the only difference on how you install them.
Here is the solution: I needed to edit my AppDelegate didFinishLaunchingWithOptions method to reflect the following:
`Parse.enableLocalDatastore()
Parse.setApplicationId("...",
clientKey: "...")
PFTwitterUtils.initializeWithConsumerKey("...", consumerSecret:"...")`
Hope this helps whoever has this problem in the future.

iOS 9 error while running Worklight 6.1 Application

We have tried to run WL 6.1 Fix Pack FP02 app on iOS 9 and got the following error in main.m file:
‘Application windows are expected to have a root view controller at the end of application launch’
The exception is thrown on this line of main.m:
int retVal = UIApplicationMain(argc, argv, appClass, #”MyAppDelegate”);
Any help would be greatly appreciated.
Below is the stack trace from xcode 7 :
Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'Application windows are expected to have a root view controller at the end of application launch'
*** First throw call stack:
(
0 CoreFoundation 0x047e0a94 __exceptionPreprocess + 180
1 libobjc.A.dylib 0x0429fe02 objc_exception_throw + 50
2 CoreFoundation 0x047e092a +[NSException raise:format:arguments:] + 138
3 Foundation 0x00f0e3e6 -[NSAssertionHandler handleFailureInMethod:object:file:lineNumber:description:] + 118
4 UIKit 0x012b3568 -[UIApplication _runWithMainScene:transitionContext:completion:] + 3674
5 UIKit 0x012d6905 __84-[UIApplication _handleApplicationActivationWithScene:transitionContext:completion:]_block_invoke3171 + 68
6 UIKit 0x012afbae -[UIApplication workspaceDidEndTransaction:] + 163
7 FrontBoardServices 0x07c1cccc __37-[FBSWorkspace clientEndTransaction:]_block_invoke_2 + 71
8 FrontBoardServices 0x07c1c7a3 __40-[FBSWorkspace _performDelegateCallOut:]_block_invoke + 54
9 FrontBoardServices 0x07c3a1cb -[FBSSerialQueue _performNext] + 184
10 FrontBoardServices 0x07c3a602 -[FBSSerialQueue _performNextFromRunLoopSource] + 52
11 FrontBoardServices 0x07c398fe FBSSerialQueueRunLoopSourceHandler + 33
12 CoreFoundation 0x046fae7f __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION__ + 15
13 CoreFoundation 0x046f0b0b __CFRunLoopDoSources0 + 523
14 CoreFoundation 0x046eff28 __CFRunLoopRun + 1032
15 CoreFoundation 0x046ef866 CFRunLoopRunSpecific + 470
16 CoreFoundation 0x046ef67b CFRunLoopRunInMode + 123
17 UIKit 0x012af497 -[UIApplication _run] + 540
18 UIKit 0x012b4cc1 UIApplicationMain + 160
19 MYAPP 0x00100f5d main + 157
20 libdyld.dylib 0x04c8ba21 start + 1
)
libc++abi.dylib: terminating with uncaught exception of type NSException
Update:
Tested with the provided Hello World project - failing
Tested with the latest available iFix - working
Please upgrade.
Without proper example that can be debugged it is difficult to answer, but it should be noted that for applications compiled with Xcode 7 to correctly function you need to make sure, at minimum, to make the following tweaks:
Disable Bitcode, as it is currently not supported.
Correctly define ATS (either allow all addresses, or correctly setup the client application with HTTPS, and the server with TLS 1.2 support).
Read more about ATS and Bitcode, here: https://developer.ibm.com/mobilefirstplatform/2015/09/09/ats-and-bitcode-in-ios9/
See if that resolves this issue. If not, you must provide an application with reproduction steps.
You should also note that 6.1 Fix Pack 2 is extremely old and you should, as an IBM customer, login to IBM Fix Central and download the latest available iFix (for Studio and Server) and upgrade. This latest iFix also contains iOS 9 related fixes, so it is advised to test with it first, in addition to the above required changes for applications compiled in Xcode 7.
From the provided example project, you are not even using Fix Pack 2, but 1. Even older...
Application windows are expected to have a root view controller at the end of application launch’
This error is caused when there is no view controller for the app to go to after the launch. This could be because you have not created one yet because you started with an empty application, you deleted the view controller, or it might be you deleted the entrance point to the main view controller.

Could not find a storyboard named

I have problem when I try to launch my app in iOS simulator,
I need someone to fix this please, I have tried everything but still I have the same problem
I got this error :
Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: 'Could not find a storyboard named 'MainStoryboard_iPhone.storyboard' in bundle NSBundle </Users/iYousef911/Library/Application Support/iPhone Simulator/7.1/Applications/F00ED8C4-145B-43C0-ACDA-C41EDC01D824/Azkar.app> (loaded)'
*** First throw call stack:
(
0 CoreFoundation 0x029c21e4 __exceptionPreprocess + 180
1 libobjc.A.dylib 0x027418e5 objc_exception_throw + 44
2 UIKit 0x01965400 -[UIStoryboard name] + 0
3 UIKit 0x01401692 -[UIApplication _loadMainStoryboardFileNamed:bundle:] + 53
4 UIKit 0x01401949 -[UIApplication _loadMainInterfaceFile] + 245
5 UIKit 0x0140054e -[UIApplication _runWithURL:payload:launchOrientation:statusBarStyle:statusBarHidden:] + 543
6 UIKit 0x01414f92 -[UIApplication handleEvent:withNewEvent:] + 3517
7 UIKit 0x01415555 -[UIApplication sendEvent:] + 85
8 UIKit 0x01402250 _UIApplicationHandleEvent + 683
9 GraphicsServices 0x03d21f02 _PurpleEventCallback + 776
10 GraphicsServices 0x03d21a0d PurpleEventCallback + 46
11 CoreFoundation 0x0293dca5 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE1_PERFORM_FUNCTION__ + 53
12 CoreFoundation 0x0293d9db __CFRunLoopDoSource1 + 523
13 CoreFoundation 0x0296868c __CFRunLoopRun + 2156
14 CoreFoundation 0x029679d3 CFRunLoopRunSpecific + 467
15 CoreFoundation 0x029677eb CFRunLoopRunInMode + 123
16 UIKit 0x013ffd9c -[UIApplication _run] + 840
17 UIKit 0x01401f9b UIApplicationMain + 1225
18 Azkar 0x00002a4d main + 141
19 libdyld.dylib 0x0325f701 start + 1
)
libc++abi.dylib: terminating with uncaught exception of type NSException
(lldb)
This may be due to different reasons. Check the below:
Check the spelling of your storyboard name. Maybe it is different or capital letters may be different
Check your bundle resources contain this storyboard from by selecting Target->Build Phases->Copy Bundle Resources. If not add it by the below plus button.
Delete your app from the iOS Simulator. Then reinstall the app.
Try to rename the storyboard and apply same name in Main storyboard file base name in your application plist file.
I know this is an old post but just in case someone wanders in here with a similar problem. My issue was we have over a dozen targets and I was not selecting them when I created the SB.
In the left hand column, under File Inspector, make sure you check the membership that the file should belong to.
In info.plist please check if values for properties UISceneStoryboardFile and UIMainStoryboardFile are correct
<key>UISceneStoryboardFile</key>
<string>[MY_PROJECT_NAME]</string>
and
<key>UIMainStoryboardFile</key>
<string>[MY_PROJECT_NAME]</string>
In my case, I accidentally mistype the name of the storyboard……
The cache is messing up everything...run this on your terminal and make sure everything inside gets cleaned up...
sudo rm -rf $HOME/Library/Developer/Xcode/DerivedData/
I have this problem but it it fixed by. there is storyboard name problem. I have my all View Controllers in Main.storyboard so there the name is "Main" and after this, write the storyboard Identifier.

Resources