Always stop in App delegate after enabling All exceptions break point
Only enable Objective-C breakpoints.
To see the actual statement that is causing the error add an exception breakpoint:
From the Main Menu Debug:Breakpoints:Create Exception Breakpoint.
Right-click the breakpoint and set the exception to Objective-C. This will ignore other types of exceptions such as from C++. There are parts of the APIs that use exceptions such as Core Data (Apple is Special).
Add an action: "po $arg1".
Run the app to get the breakpoint and you will be at the line that causes the exception and the error message will be in the debugger console.
Breakpoint example:
Always trigger the all exceptions break point
Possible solutions for it could be:
- Added custom font can cause this issue so, apparently delete (replace) it, somewhere in project is still his reference which causes C++ exception.
So, Delete or Replace all references to those fonts, Clean the project and check.
- Change from All Exceptions to Objective-C Exceptions in All Exceptions.
Check this answers will help more:
Xcode throws an exception in Main() in iOS 8 with 'all exceptions' breakpoint
Always stop in App delegate after enabling All exceptions break point
Try and check if it help:)
App SIGABRTs on AppDelegate
It turns out that I had an unrecognized selector sent to instance 0xABC123
exception being thrown. I only discovered this because I used the inline closure:
NSSetUncaughtExceptionHandler { exception in
print(exception)
print(exception.callStackSymbols)
}
at the end of my application(_:didFinishLaunchingWithOptions:) method in my AppDelegate. For some reason the symbolic any exception breakpoint wasn't providing me with the same amount of detail.
Xcode throws an exception in Main() in iOS 8 with 'all exceptions' breakpoint
As stated in the comments, you should turn off catching the C++ exceptions by editing your All Exceptions breakpoint.
In order to do that, right click on your breakpoint and change Exception from All to Objective-C:
Exceptions in C++ code are part of normal app functionality. However, exception breakpoint is not catching unhandled but every raised exceptions, even when they're handled correctly later on, hence the stop in execution.
xCode - App stop on a not existing breakpoint
before assign value to MCCVsISDCode kindly init it first.
Exception breakPoint at [self.window makeKeyAndVisible]
Edit Exception breakpoint like this-
And select Objective C like this-
Hope this helps!
How to debug with breakpoint when crash line is the App Delegate?
In this case you can set exception breakpoints
here
and then here (in Exceptions -> All)
xCode - App stop on a not existing breakpoint
before assign value to MCCVsISDCode kindly init it first.
Xcode always stopping at main.m after a crash
They changed the behavior, follow this tutorial to break on all exceptions
EDIT:(Link might rot, so I will duplicate the info here)
One of the hidden gems in Xcode 4.2 is the “Exception Breakpoint” feature. Once you enable it, your debugging life becomes much easier because whenever an exception is thrown in your app, Xcode will bring up the line of code that caused the exception to occur. This is particularly useful if your call stack window is empty (which I have seen happen sometimes while working on iOS apps). Instead of relying on a brief error message in the Output pane, which doesn’t contain much more than the type of exception and its error message, you get to see exactly where the problem is!
You can add an Exception Breakpoint by opening up the Breakpoint Navigator pane, and clicking on the X button in the bottom left corner:
After clicking the “Add Exception Breakpoint…” menu item, you will see this breakpoint configuration view open up:
Click the Done button and you will the new Exception Breakpoint in your list of breakpoints. If you want to have all of your Xcode workspaces include the Exception Breakpoint, right-click (Ctrl + click) on it and open the “Move Breakpoint To” menu item:
After clicking “User” in the submenu, you will see that the Exception Breakpoint is in the User group of breakpoints. Open up another project and it automatically be included in the list of breakpoints.
Happy debugging!
Related Topics
Info.Plist Utility Error: "Info.Plist Couldn't Be Opened Because There Is No Such File"
How to Dynamically Format a Number to Have Commas in a Uitextfield Entry
Perform UI Changes on Main Thread Using Dispatch_Async or Performselectoronmainthread
Xcode 6.4/7 Crashing After El Capitan Beta
Schedule Number of Local Notifications
Watchkit: Unable to Find Interface Controller Class
Xcode 8 Gm Seed Storyboard Layout Issue
How to Pass Swift Enum with @Objc Tag
Uicollectionview - iOS 10 - Crash on iPhone 6 Plus Simulator But Works on Real Device
How to Import Existing Objective C Classes in Swift
How to Tell If Blocks in Loop All Have Completed Executing
Detect Which App Is Currently Running on iOS Using Sysctl
Is There Any Limitation to Distribution of Apps in iOS Enterprise Program
How to Get the Result Value of Alamofire.Request().Responsejson in Swift 2
Communicating With/Opening Containing App from Share Extension