App unable to simultaneously satisfy constraints between UIInputSetContainerView UITextEffectsView when Hotspot enabled

Hi everyone,


I ran into this issue today after I deployed an app on to my iPhone 5 (Running iOS9) while I was using Personal Hotspot to connect my MacBook Pro to internet.


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) 
(
    "<NSLayoutConstraint:0x14653370 V:|-(20)-[UIInputSetContainerView:0x146524f0]   (Names: '|':UITextEffectsWindow:0x146717d0 )>",
    "<NSLayoutConstraint:0x14638d40 'UIInputWindowController-top' V:|-(0)-[UIInputSetContainerView:0x146524f0]   (Names: '|':UITextEffectsWindow:0x146717d0 )>"
)
Will attempt to recover by breaking constraint 
<NSLayoutConstraint:0x14653370 V:|-(20)-[UIInputSetContainerView:0x146524f0]   (Names: '|':UITextEffectsWindow:0x146717d0 )>
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.


The conflicting constraints are highlighted in this screenshot: http://i.imgur.com/pUMt3Pz.png



Has anyone else encoutner this problem? Is there anything I can do from the app's code or in Xcode to prevent this from happening? or is this a bug in Xcode/iOS?

Replies

hi I am getting the same error (exactly the same error) . If you are able to resolve please let know. I tried many solutions ..still same error ..please reply

Hi, I got a solution. For me this error was being generated when I accepting the incoming phone call.

So in the interruption section I put the following code and solved



for(UIWindow *window in [[UIApplication sharedApplication] windows])
{
  if([window.class.description isEqual:@"UITextEffectsWindow"])
    { 
        [window removeConstraints:window.constraints];
    }
 }

Hi Wvega,


I get this same issue using MacBook Pro (15inch Retina, Mid 2015), OS X El Capitan (10.11.1), XCode 7.1, iOS 9.1 and an iPad Air 2. The debug warning happens between starting the app in Main and didFinishLaunchingWithOptions (in AppDelegate.m) when:


1). I start my app (or even the default tabbed project).

2). I split the view and run a second app such as calendar

3). I close my app down

4). I restart the app


On 4) restarting the app (in split view) I get the same debug warning as you are getting.


At this point I'm tending to think it's an iOS issue but as farisc has pointed out, there may be workarounds you can do.


I'm not sure at the moment how I can remove the constraint before didFinishLaunchingWithOptions, but I bet there's a way ;-)


Update: I've submitted a bug report on this issue. Feedback so far is that it's a duplicate of 21732984 (that has the status of Open).

An incoming call causes this debug error to show up for me, too, running my app on an iPhone 5 running iOS 9.2.1. Seems like an iOS bug.

+1 for me.


This may be addressable by adjusting a top/bottom constraint for the view itself. However, something this boilerplate 'should' be handled by the frameworks already.

Ditto here on this same error. I see mine with on iPad, no phone calls involved. Mine pops up intermittantly, maybe every fifth to tenth time of running the app. Please post back if you find a solution.

I tried this solution and it does get rid fo the constraint error but I see this in degug:


2016-08-17 14:49:13.819 xxxxxxxxxx _BSMachError: (os/kern) invalid capability (20)
2016-08-17 14:49:13.820 xxxxxxxxxx _BSMachError: (os/kern) invalid name (15)


Anyone know if this has been resolved?