I’m getting Auto Layout constraint conflict warnings related to AVPlayerView in my project.
I’ve reproduced the issue on macOS Tahoe 26.2.
The conflict appears to originate inside AVPlayerView itself, between its internal subviews, rather than in my own layout code.
This issue can be easily reproduced in an empty project by simply adding an AVPlayerView as a subview using the code below.
class ViewController: NSViewController {
override func viewDidLoad() {
super.viewDidLoad()
let playerView = AVPlayerView()
view.addSubview(playerView)
}
}
After presenting that view controller, the following Auto Layout constraint conflict warnings appear in the console:
Conflicting constraints detected: <decode: bad range for [%@] got [offs:346 len:1057 within:0]>.
Will attempt to recover by breaking <decode: bad range for [%@] got [offs:1403 len:81 within:0]>.
Unable to simultaneously satisfy constraints:
(
"<NSLayoutConstraint:0xb33c29950 H:|-(0)-[AVDesktopPlayerViewContentView:0x10164dce0](LTR) (active, names: '|':AVPlayerView:0xb32ecc000 )>",
"<NSLayoutConstraint:0xb33c299a0 AVDesktopPlayerViewContentView:0x10164dce0.right == AVPlayerView:0xb32ecc000.right (active)>",
"<NSAutoresizingMaskLayoutConstraint:0xb33c62850 h=--& v=--& AVPlayerView:0xb32ecc000.width == 0 (active)>",
"<NSLayoutConstraint:0xb33d46df0 H:|-(0)-[AVEventPassthroughView:0xb33cfb480] (active, names: '|':AVDesktopPlayerViewContentView:0x10164dce0 )>",
"<NSLayoutConstraint:0xb33d46e40 AVEventPassthroughView:0xb33cfb480.trailing == AVDesktopPlayerViewContentView:0x10164dce0.trailing (active)>",
"<NSLayoutConstraint:0xb33ef8320 NSGlassView:0xb33ed8c00.trailing == AVEventPassthroughView:0xb33cfb480.trailing - 6 (active)>",
"<NSLayoutConstraint:0xb33ef8460 NSGlassView:0xb33ed8c00.width == 180 (active)>",
"<NSLayoutConstraint:0xb33ef84b0 NSGlassView:0xb33ed8c00.leading >= AVEventPassthroughView:0xb33cfb480.leading + 6 (active)>"
)
Will attempt to recover by breaking constraint
<NSLayoutConstraint:0xb33ef8460 NSGlassView:0xb33ed8c00.width == 180 (active)>
Set the NSUserDefault NSConstraintBasedLayoutVisualizeMutuallyExclusiveConstraints to YES to have -[NSWindow visualizeConstraints:] automatically called when this happens. And/or, set a symbolic breakpoint on LAYOUT_CONSTRAINTS_NOT_SATISFIABLE to catch this in the debugger.
Is it system bug or maybe someone knows how to fix that?
Thank you.