IB gives superfluous warnings on UIStackView with dynamic height AutoLayout content

Originator:bruno
Number:rdar://21629383 Date Originated:01-Jul-2015 12:28 PM
Status:Closed Resolved:Duplicate of 21629383.
Product:iOS SDK Product Version:
Classification:Enhancement Reproducible:Not Applicable
 
Summary:
While attempting to add padding to the `arrangedSubviews` of a `UIStackView`, I added regular UIViews as the arrangedSubviews and added labels with constraints within those. The label have a dynamic height, in that they are set to `numberOfLines = 0` and their text could change. 

IB renders this perfectly, and it renders perfectly on device as well. However, IB gives multiple warnings, indicating that the actual dimensions of the views in the UIStackView are actually different. These warnings shouldn’t be there in this configuration and with this result.

Steps to Reproduce:
1. Unarchive attached .zip.
2. Open NWAAlertController project.
3. Open Main.Storyboard.
4. View warnings in ViewController scene.

Expected Results:
No warnings should appear.

Actual Results:
Four warnings appear;

2 of them due to IB determining that the UIViews containing the UILabels are actually height 0.
2 of them due to IB determining that the UIButtons are height 30, even though I constrained them to height 40.

Regression:
n/a

Notes:
The project can also be found on Github: https://github.com/SpacyRicochet/NWAAlertController/commit/b73a455cd91499d1cdff43061a5f6977d80fca47

Comments

Marked and closed as dupe of rdar://21629383.


Please note: Reports posted here will not necessarily be seen by Apple. All problems should be submitted at bugreport.apple.com before they are posted here. Please only post information for Radars that you have filed yourself, and please do not include Apple confidential information in your posts. Thank you!