title: Getting constraints to work in size classes
body: <p>So, I'm playing around with size classes in Xcode 6 beta. I set up some constraints on an image such that it is in a different position based on size classes corresponding to iPhone portrait and landscape.</p>
  
  <p>The constraints are visible in the images below. As you can see, when I am in Compact/Compact, some constraints are "installed" while others are not, and in Compact/Regular, other constraints are installed.</p>
  
  <p><img src="https://i.stack.imgur.com/QAG6G.png" alt="Compact/Compact">
  <img src="https://i.stack.imgur.com/GWWzr.png" alt="Compact/Regular"></p>
  
  <p>However, I get an error (slightly visible in both screenshots) basically claiming that my uninstalled constraints are interfering with my installed constraints (which, if they were run at the same time, is true) but shouldn't the uninstalled constraints for each size class not even be run? None of the installed constraints cause issues with each other.</p>
  
  <p>The error that shows up is:</p>
  
  <pre><code>2014-06-30 21:14:26.215 TV Tracker[26417:1434692] SetAppThreadPriority: setpriority failed with error 45
  2014-06-30 21:14:26.372 TV Tracker[26417:1434692] 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) 
  (
  "&lt;NSLayoutConstraint:0x10bb11da0 H:|-(24)-[UILabel:0x10bb4db70'TV Tracker uses your Trak...']   (Names: '|':UIControl:0x10bb2db60 )&gt;",
  "&lt;NSLayoutConstraint:0x10bb11df0 H:[UIImageView:0x10bb44740]-(&gt;=18)-[UILabel:0x10bb4db70'TV Tracker uses your Trak...']&gt;",
  "&lt;NSLayoutConstraint:0x10bb2f420 H:|-(20)-[UIButton:0x10bb35470'Sign In']   (Names: '|':UIControl:0x10bb2db60 )&gt;",
  "&lt;NSLayoutConstraint:0x10bb2f470 UIButton:0x10bb35470'Sign In'.leading == UIImageView:0x10bb44740.leading&gt;"
  )
  
  Will attempt to recover by breaking constraint 
  &lt;NSLayoutConstraint:0x10bb11df0 H:[UIImageView:0x10bb44740]-(&gt;=18)-[UILabel:0x10bb4db70'TV Tracker uses your Trak...']&gt;
  
  Make a symbolic breakpoint at UIViewAlertForUnsatisfiableConstraints to catch this in the debugger.
  The methods in the UIConstraintBasedLayoutDebugging category on UIView listed in &lt;UIKit/UIView.h&gt; may also be helpful.
  2014-06-30 21:14:26.373 TV Tracker[26417:1434692] 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) 
  (
  "&lt;NSLayoutConstraint:0x10bb11e90 H:[UILabel:0x10bb4db70'TV Tracker uses your Trak...']-(23)-|   (Names: '|':UIControl:0x10bb2db60 )&gt;",
  "&lt;NSLayoutConstraint:0x10bb11ee0 UILabel:0x10bb4db70'TV Tracker uses your Trak...'.trailing == UIButton:0x10bb44ec0'Register'.trailing&gt;",
  "&lt;NSLayoutConstraint:0x10bb2f510 H:[UIButton:0x10bb44ec0'Register']-(20)-|   (Names: '|':UIControl:0x10bb2db60 )&gt;"
  )
  
  Will attempt to recover by breaking constraint 
  &lt;NSLayoutConstraint:0x10bb11ee0 UILabel:0x10bb4db70'TV Tracker uses your Trak...'.trailing == UIButton:0x10bb44ec0'Register'.trailing&gt;
  
  Make a symbolic breakpoint at UIViewAlertForUnsatisfiableConstraints to catch this in the debugger.
  The methods in the UIConstraintBasedLayoutDebugging category on UIView listed in &lt;UIKit/UIView.h&gt; may also be helpful.
  2014-06-30 21:14:26.388 TV Tracker[26417:1434692] 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) 
  (
  "&lt;NSAutoresizingMaskLayoutConstraint:0x10bb49e10 h=-&amp;- v=-&amp;- UIControl:0x10bb2db60.width == UIViewControllerWrapperView:0x10d102000.width&gt;",
  "&lt;NSAutoresizingMaskLayoutConstraint:0x10bb55d10 h=-&amp;- v=-&amp;- UIViewControllerWrapperView:0x10d102000.width == UINavigationTransitionView:0x10bc6f770.width&gt;",
  "&lt;NSAutoresizingMaskLayoutConstraint:0x10bb3cda0 h=-&amp;- v=-&amp;- UINavigationTransitionView:0x10bc6f770.width == UILayoutContainerView:0x10bc6e3e0.width&gt;",
  "&lt;NSAutoresizingMaskLayoutConstraint:0x10bb29960 h=-&amp;- v=-&amp;- UILayoutContainerView:0x10bc6e3e0.width == UITransitionView:0x10bc73670.width&gt;",
  "&lt;NSAutoresizingMaskLayoutConstraint:0x10bb559e0 h=-&amp;- v=-&amp;- UITransitionView:0x10bc73670.width == UIWindow:0x10d068e70.width&gt;",
  "&lt;NSAutoresizingMaskLayoutConstraint:0x10bb56880 h=--- v=--- H:[UIWindow:0x10d068e70(320)]&gt;",
  "&lt;NSLayoutConstraint:0x10bb2f420 H:|-(20)-[UIButton:0x10bb35470'Sign In']   (Names: '|':UIControl:0x10bb2db60 )&gt;",
  "&lt;NSLayoutConstraint:0x10bb2f470 UIButton:0x10bb35470'Sign In'.leading == UIImageView:0x10bb44740.leading&gt;",
  "&lt;NSLayoutConstraint:0x10bb44570 UIControl:0x10bb2db60.centerX == UIImageView:0x10bb44740.centerX&gt;",
  "&lt;NSLayoutConstraint:0x10bb3c840 H:[UIImageView:0x10bb44740(92)]&gt;"
  )
  
  Will attempt to recover by breaking constraint 
  &lt;NSLayoutConstraint:0x10bb3c840 H:[UIImageView:0x10bb44740(92)]&gt;
  
  Make a symbolic breakpoint at UIViewAlertForUnsatisfiableConstraints to catch this in the debugger.
  The methods in the UIConstraintBasedLayoutDebugging category on UIView listed in &lt;UIKit/UIView.h&gt; may also be helpful.
  2014-06-30 21:14:26.389 TV Tracker[26417:1434692] 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) 
  (
  "&lt;_UILayoutSupportConstraint:0x10bd1c8a0 V:[_UILayoutGuide:0x10bb4acb0(64)]&gt;",
  "&lt;_UILayoutSupportConstraint:0x10bd1fbf0 V:|-(0)-[_UILayoutGuide:0x10bb4acb0]   (Names: '|':UIControl:0x10bb2db60 )&gt;",
  "&lt;NSAutoresizingMaskLayoutConstraint:0x10bb56d40 h=-&amp;- v=-&amp;- UIControl:0x10bb2db60.height == UIViewControllerWrapperView:0x10d102000.height&gt;",
  "&lt;NSAutoresizingMaskLayoutConstraint:0x10bb56c60 h=-&amp;- v=-&amp;- UIViewControllerWrapperView:0x10d102000.height == UINavigationTransitionView:0x10bc6f770.height&gt;",
  "&lt;NSAutoresizingMaskLayoutConstraint:0x10bb3cbb0 h=-&amp;- v=-&amp;- UINavigationTransitionView:0x10bc6f770.height == UILayoutContainerView:0x10bc6e3e0.height&gt;",
  "&lt;NSAutoresizingMaskLayoutConstraint:0x10bb4a920 h=-&amp;- v=-&amp;- UILayoutContainerView:0x10bc6e3e0.height == UITransitionView:0x10bc73670.height&gt;",
  "&lt;NSAutoresizingMaskLayoutConstraint:0x10bb0e3a0 h=-&amp;- v=-&amp;- UITransitionView:0x10bc73670.height == UIWindow:0x10d068e70.height&gt;",
  "&lt;NSAutoresizingMaskLayoutConstraint:0x10bb44d20 h=--- v=--- V:[UIWindow:0x10d068e70(568)]&gt;",
  "&lt;NSLayoutConstraint:0x10bb44520 UIControl:0x10bb2db60.centerY == UIImageView:0x10bb44740.centerY&gt;",
  "&lt;NSLayoutConstraint:0x10bb445c0 V:[_UILayoutGuide:0x10bb4acb0]-(24)-[UIImageView:0x10bb44740]&gt;",
  "&lt;NSLayoutConstraint:0x10bb49b60 V:[UIImageView:0x10bb44740(100)]&gt;"
  )
  
  Will attempt to recover by breaking constraint 
  &lt;NSLayoutConstraint:0x10bb49b60 V:[UIImageView:0x10bb44740(100)]&gt;
  
  Make a symbolic breakpoint at UIViewAlertForUnsatisfiableConstraints to catch this in the debugger.
  The methods in the UIConstraintBasedLayoutDebugging category on UIView listed in &lt;UIKit/UIView.h&gt; may also be helpful.
  2014-06-30 21:14:26.396 TV Tracker[26417:1434692] 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) 
  (
  "&lt;_UILayoutSupportConstraint:0x10bd13470 V:[_UILayoutGuide:0x10bb4c690(0)]&gt;",
  "&lt;_UILayoutSupportConstraint:0x10bd13410 _UILayoutGuide:0x10bb4c690.bottom == UIControl:0x10bb2db60.bottom&gt;",
  "&lt;NSAutoresizingMaskLayoutConstraint:0x10bb56d40 h=-&amp;- v=-&amp;- UIControl:0x10bb2db60.height == UIViewControllerWrapperView:0x10d102000.height&gt;",
  "&lt;NSAutoresizingMaskLayoutConstraint:0x10bb56c60 h=-&amp;- v=-&amp;- UIViewControllerWrapperView:0x10d102000.height == UINavigationTransitionView:0x10bc6f770.height&gt;",
  "&lt;NSAutoresizingMaskLayoutConstraint:0x10bb3cbb0 h=-&amp;- v=-&amp;- UINavigationTransitionView:0x10bc6f770.height == UILayoutContainerView:0x10bc6e3e0.height&gt;",
  "&lt;NSAutoresizingMaskLayoutConstraint:0x10bb4a920 h=-&amp;- v=-&amp;- UILayoutContainerView:0x10bc6e3e0.height == UITransitionView:0x10bc73670.height&gt;",
  "&lt;NSAutoresizingMaskLayoutConstraint:0x10bb0e3a0 h=-&amp;- v=-&amp;- UITransitionView:0x10bc73670.height == UIWindow:0x10d068e70.height&gt;",
  "&lt;NSAutoresizingMaskLayoutConstraint:0x10bb44d20 h=--- v=--- V:[UIWindow:0x10d068e70(568)]&gt;",
  "&lt;NSLayoutConstraint:0x10bb11e40 UIControl:0x10bb2db60.centerY == UILabel:0x10bb4db70'TV Tracker uses your Trak...'.centerY + 0.25&gt;",
  "&lt;NSLayoutConstraint:0x10bb2f3d0 V:[UILabel:0x10bb4db70'TV Tracker uses your Trak...']-(91)-[_UILayoutGuide:0x10bb4c690]&gt;",
  "&lt;NSLayoutConstraint:0x10bb2d790 V:[UILabel:0x10bb4db70'TV Tracker uses your Trak...'(69)]&gt;"
  )
  
  Will attempt to recover by breaking constraint 
  </code></pre>
  
  <p></p>
  
  <pre><code>Make a symbolic breakpoint at UIViewAlertForUnsatisfiableConstraints to catch this in the debugger.
  The methods in the UIConstraintBasedLayoutDebugging category on UIView listed in &lt;UIKit/UIView.h&gt; may also be helpful.
  </code></pre>
  
  <p></p>
  
  <p>My sidebar for the Compact/Compact constraints look like
  <img src="https://i.stack.imgur.com/HI3ov.png" alt="C/C sidebar"></p>
  
  <p>My sidebar for the Compact/Regular constraints look like
  <img src="https://i.stack.imgur.com/sgNWO.png" alt="C/R sidebar"></p>
  
  <p>My view hierarchy for this login controller:
  <img src="https://i.stack.imgur.com/w1kHl.png" alt="view hierarchy"></p>