ものぐさ日記(仮)

特にテーマはありません。仕事のこと、趣味のこと、思いついたこと、だらだら綴っていきます。

【iOSアプリ開発】AutoLayout 警告

備忘です。

iOS6時代に作ったアプリをiOS11 64bit環境に移行しており、結構グロッキー状態であるが、特に Autolayout の設定を入れていないのに、コンソールに Autolayout 絡みの警告(以下)がめっさ出力される。

 

2018-03-06 09:39:00.393356+0900 Hoge[1407:1003191] 
[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) 
(
    "",
    "",
    "",
    "<NSLayoutConstraint:0x1c0688660 'UISV-alignment' _UIButtonBarButton:0x10b8f1be0.centerY == UIView:0x10b8f0890.centerY   (active)>",
    "<NSLayoutConstraint:0x1c049e780 'UISV-canvas-connection' UILayoutGuide:0x1c03b4040'UIViewLayoutMarginsGuide'.top == _UILayoutSpacer:0x1c01d7250'UISV-alignment-spanner'.top   (active)>",
    "<NSLayoutConstraint:0x1c0688480 'UISV-canvas-connection' UILayoutGuide:0x1c03b4040'UIViewLayoutMarginsGuide'.centerY == _UIButtonBarButton:0x10b8f1be0.centerY   (active)>",
    "<NSLayoutConstraint:0x1c0688200 'UISV-spanning-boundary' _UILayoutSpacer:0x1c01d7250'UISV-alignment-spanner'.top <= UIView:0x10b8f0890.top   (active)>",
    "<NSLayoutConstraint:0x1c0492980 'UIView-bottomMargin-guide-constraint' V:[UILayoutGuide:0x1c03b4040'UIViewLayoutMarginsGuide']-(9)-|   (active, names: '|':_UIButtonBarStackView:0x10b8c0a90 )>",
    "<NSLayoutConstraint:0x1c04928e0 'UIView-topMargin-guide-constraint' V:|-(10)-[UILayoutGuide:0x1c03b4040'UIViewLayoutMarginsGuide']   (active, names: '|':_UIButtonBarStackView:0x10b8c0a90 )>"
)

Will attempt to recover by breaking constraint 
<NSLayoutConstraint:0x1c0688200 'UISV-spanning-boundary' _UILayoutSpacer:0x1c01d7250'UISV-alignment-spanner'.top <= UIView:0x10b8f0890.top   (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.

 

現状オチは特にないけど、後々、調査し対応するかもです。

 

終わり