apache / cordova-ios

Apache Cordova iOS
https://cordova.apache.org/
Apache License 2.0
2.16k stars 989 forks source link

CRITICAL! Getting error "[LayoutConstraints] Unable to simultaneously satisfy constraints." when user touches HTML SELECT list #1147

Closed epabst closed 3 years ago

epabst commented 3 years ago

Issue Type

Description

The app I'm building has an HTML SELECT element in it with some options. Here is the DOM:

<select id="formControl12" class="form-control">
  <option label="3" value="3"></option>
  <option label="4" value="4"></option>
  <option label="5" value="5"></option>
</select>

When I run "cordova build ios" and run it on an ios device simulator, and click on the select list, I get the following error that is making my app NOT USABLE on ios devices:

2021-09-16 06:30:32.625254-0600 Future Balance[1035:28945] [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:0x6000033c0730 h=--& v=--& _UIToolbarContentView:0x7fbbcd65a540.height == 0   (active)>",
    "<NSLayoutConstraint:0x6000033ad1d0 V:|-(0)-[_UIButtonBarStackView:0x7fbbcd610170]   (active, names: '|':_UIToolbarContentView:0x7fbbcd65a540 )>",
    "<NSLayoutConstraint:0x6000033ad220 _UIButtonBarStackView:0x7fbbcd610170.bottom == _UIToolbarContentView:0x7fbbcd65a540.bottom   (active)>",
    "<NSLayoutConstraint:0x6000033ddae0 UIButtonLabel:0x7fbbcd68ea30.centerY == _UIModernBarButton:0x7fbbcd47a0e0'Done'.centerY + 0.5   (active)>",
    "<NSLayoutConstraint:0x6000033dbde0 'TB_Baseline_Baseline' _UIModernBarButton:0x7fbbcd47a0e0'Done'.lastBaseline == UILayoutGuide:0x6000029d7aa0'UIViewLayoutMarginsGuide'.bottom   (active)>",
    "<NSLayoutConstraint:0x6000033dbe30 'TB_Top_Top' V:|-(>=0)-[_UIModernBarButton:0x7fbbcd47a0e0'Done']   (active, names: '|':_UIButtonBarButton:0x7fbbcd68c990 )>",
    "<NSLayoutConstraint:0x6000033d7de0 'UIButtonBar.maximumAlignmentSize' _UIButtonBarButton:0x7fbbcd68c990.height == UILayoutGuide:0x6000029d4700'UIViewLayoutMarginsGuide'.height   (active)>",
    "<NSLayoutConstraint:0x6000033acff0 'UIView-bottomMargin-guide-constraint' V:[UILayoutGuide:0x6000029d4700'UIViewLayoutMarginsGuide']-(0)-|   (active, names: '|':_UIButtonBarStackView:0x7fbbcd610170 )>",
    "<NSLayoutConstraint:0x6000033dbd40 'UIView-bottomMargin-guide-constraint' V:[UILayoutGuide:0x6000029d7aa0'UIViewLayoutMarginsGuide']-(16)-|   (active, names: '|':_UIButtonBarButton:0x7fbbcd68c990 )>",
    "<NSLayoutConstraint:0x6000033acf50 'UIView-topMargin-guide-constraint' V:|-(0)-[UILayoutGuide:0x6000029d4700'UIViewLayoutMarginsGuide']   (active, names: '|':_UIButtonBarStackView:0x7fbbcd610170 )>"
)

Will attempt to recover by breaking constraint 
<NSLayoutConstraint:0x6000033ddae0 UIButtonLabel:0x7fbbcd68ea30.centerY == _UIModernBarButton:0x7fbbcd47a0e0'Done'.centerY + 0.5   (active)>

Make a symbolic breakpoint at UIViewAlertForUnsatisfiableConstraints to catch this in the debugger.
The methods in the UIConstraintBasedLayoutDebugging category on UIView listed in <UIKitCore/UIView.h> may also be helpful.

The user sees the bottom part of the screen as a selector but with no options showing up to pick from.

See https://stackoverflow.com/questions/69214395/ios-cordova-getting-error-layoutconstraints-unable-to-simultaneously-satisfy for screenshots.

Information

This happens with multiple cordova apps I tried in ios.

Command or Code

Have any