Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Debug logging regarding constraint satisfaction #2

Closed
technimad opened this issue Feb 22, 2018 · 2 comments
Closed

Debug logging regarding constraint satisfaction #2

technimad opened this issue Feb 22, 2018 · 2 comments
Labels
bug Something isn't working

Comments

@technimad
Copy link

Short description of the issue

When I start the app, I see in the debug window debug logging which mentions a problem with constraint satisfaction.
I don't know if this indicates a real problem, but mentioning this here might help development.

Issue type

Bug?

What is actually happening?

While navigating through the list of 'Programma's', the xcode debug window shows logs like:

2018-02-22 19:40:25.101 [Debug] [ProgramViewController.swift:48] setupPaginator() > Page 1 of 12 (20 episodes)
2018-02-22 19:40:25.117455+0100 TVGemist[249:116898] [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.
(
"<NSLayoutConstraint:0x1c0487d00 UIImageView:0x102f85810.width == 1.77778*UIImageView:0x102f85810.height (active)>",
"<NSLayoutConstraint:0x1c04883e0 UILabel:0x102f85a20'NOS Pyeongchang Vandaag'.height == 35 (active)>",
"<NSLayoutConstraint:0x1c429e0f0 UILabel:0x102f904a0'22 feb. 2018 18:00'.height == 30 (active)>",
"<NSLayoutConstraint:0x1c0488660 H:[UIImageView:0x102f85810]-(0)-| (active, names: '|':TVGemist.EpisodeCollectionViewCell:0x102e87ab0 )>",
"<NSLayoutConstraint:0x1c04886b0 H:|-(0)-[UIImageView:0x102f85810] (active, names: '|':TVGemist.EpisodeCollectionViewCell:0x102e87ab0 )>",
"<NSLayoutConstraint:0x1c0488700 V:|-(0)-[UIImageView:0x102f85810] (active, names: '|':TVGemist.EpisodeCollectionViewCell:0x102e87ab0 )>",
"<NSLayoutConstraint:0x1c0488750 V:[UIImageView:0x102f85810]-(8)-[UILabel:0x102f85a20'NOS Pyeongchang Vandaag'] (active)>",
"<NSLayoutConstraint:0x1c0488840 V:[UILabel:0x102f904a0'22 feb. 2018 18:00']-(20)-| (active, names: '|':TVGemist.EpisodeCollectionViewCell:0x102e87ab0 )>",
"<NSLayoutConstraint:0x1c0488930 V:[UILabel:0x102f85a20'NOS Pyeongchang Vandaag']-(8)-[UILabel:0x102f904a0'22 feb. 2018 18:00'] (active)>",
"<NSLayoutConstraint:0x1c429e550 'UIView-Encapsulated-Layout-Height' TVGemist.EpisodeCollectionViewCell:0x102e87ab0.height == 312 (active)>",
"<NSLayoutConstraint:0x1c429e500 'UIView-Encapsulated-Layout-Width' TVGemist.EpisodeCollectionViewCell:0x102e87ab0.width == 375 (active)>"
)

Will attempt to recover by breaking constraint
<NSLayoutConstraint:0x1c04883e0 UILabel:0x102f85a20'NOS Pyeongchang Vandaag'.height == 35 (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.

These messages are repeated multiple times.

Steps to reproduce

Install app.

Extra information

Version you are using: 464d593

tvOS version: most recent (appletv is set to auto update)

Xcode version: 9.2

@4np
Copy link
Owner

4np commented Feb 22, 2018

Not really an issue, but something I should take a look at at some point. You can ignore errors like these as this will not break the app. It's merely an issue with the UI constraints and some of them are conflicting so Apple does not know which one to prefer. It might mean the a text label is a bit wider than it should be, or something is positioned a bit differently, but most likely not anything you'd notice.

@4np 4np added the bug Something isn't working label Feb 22, 2018
@4np
Copy link
Owner

4np commented Mar 28, 2018

I don't see those Storyboard warnings, closing as this doesn't seem to be an issue (anymore?)...

@4np 4np closed this as completed Mar 28, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants