-
Notifications
You must be signed in to change notification settings - Fork 1
Open
Description
The app crashes halts at a debug exception the second time the “My Profile” tab is shown.
Steps to reproduce
- Tap “My Profile” tab.
- Tap on any other tab.
- Tap “My Profile” tab again.
- Crash
The crash
The crash occurs in the -[AKTabBarView setContentView:] method on line 47 due to some contradicting auto layout constraints in the OPFUserProfileViewController.
2013-05-01 16:07:43.868 Code Stream[96082:c07] Unable to simultaneously satisfy constraints.
Probably at least one of the constraints in the following list is one you don't want. Try this: (1) look at each constraint and try to figure out which you don't expect; (2) find the code that added the unwanted constraint or constraints and fix it. (Note: If you're seeing NSAutoresizingMaskLayoutConstraints that you don't understand, refer to the documentation for the UIView property translatesAutoresizingMaskIntoConstraints)
(
"<NSAutoresizingMaskLayoutConstraint:0x13c54f20 h=--& v=--& H:[UITableViewCell:0xa246ed0(0)]>",
"<NSLayoutConstraint:0x13c4bac0 UIWebView:0xa26f620.leading == UITableViewCell:0xa246ed0.leading + 10>",
"<NSLayoutConstraint:0x13c50280 UITableViewCell:0xa246ed0.trailing == UIWebView:0xa26f620.trailing + 10>"
)
Will attempt to recover by breaking constraint
<NSLayoutConstraint:0x13c50280 UITableViewCell:0xa246ed0.trailing == UIWebView:0xa26f620.trailing + 10>
Break on objc_exception_throw to catch this in the debugger.
The methods in the UIConstraintBasedLayoutDebugging category on UIView listed in <UIKit/UIView.h> may also be helpful.
Possible fixes
- Investigate if it is
AKTabBarControllerwhich is incompatible with auto layout and in such case fixAKTabBarController. - Change all of our views to use springs and struts instead of auto layout. Most likely a huge task!
/cc @tdeekens
Reactions are currently unavailable