Skip to content

Instantly share code, notes, and snippets.

@alanmcgovern
Created April 6, 2017 17:28
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save alanmcgovern/ca456dfb11441f802b52d2f2f7602731 to your computer and use it in GitHub Desktop.
Save alanmcgovern/ca456dfb11441f802b52d2f2f7602731 to your computer and use it in GitHub Desktop.
Apr 6 18:27:22 Alans-MacBook-Pro ConflictingConstraint[37976]: [LayoutConstraints] 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:0x6000002882f0 h=--& v=--& UIButton:0x7fae80d10cc0.width == 0 (active)>",
"<NSLayoutConstraint:0x600000287e40 UIButton:0x7fae80d10cc0.width == 100 (active)>"
)
Will attempt to recover by breaking constraint
<NSLayoutConstraint:0x600000287e40 UIButton:0x7fae80d10cc0.width == 100 (active)>
Make a symbolic breakpoint at UIViewAlertForUnsatisfiableConstraints to catch this in the debugger.
The methods in the UIConstraintBasedLayoutDebugging category on UIView listed in <UIKit/UIView.h> may also be helpful.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment