⚠️ Please check your code before presenting. ⚠️
https://www.hackingwithswift.com/quick-start/swiftui/how-to-add-a-toolbar-to-the-keyboard
When you don't know, this approach may contain some bugs:
Error 1:
-[RTIInputSystemClient remoteTextInputSessionWithID:performInputOperation:] perform input operation requires a valid sessionID
Error 2:
Problem with constraints looks like:
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:0x60000213ecb0 h=--& v=--& _UIToolbarContentView:0x107e1d7b0.width == 0 (active)>",
"<NSLayoutConstraint:0x6000021659a0 H:|-(0)-[_UIButtonBarStackView:0x107d337d0] (active, names: '|':_UIToolbarContentView:0x107e1d7b0 )>",
"<NSLayoutConstraint:0x6000021659f0 H:[_UIButtonBarStackView:0x107d337d0]-(20)-| (active, names: '|':_UIToolbarContentView:0x107e1d7b0 )>"
)
Will attempt to recover by breaking constraint
<NSLayoutConstraint:0x6000021659f0 H:[_UIButtonBarStackView:0x107d337d0]-(20)-| (active, names: '|':_UIToolbarContentView:0x107e1d7b0 )>
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.
AddInstanceForFactory: No factory registered for id <CFUUID 0x60000023cc00> F8BB1C28-BAE8-11D6-9C31-00039315CD46
127491 HALC_ProxyIOContext.cpp:1328 HALC_ProxyIOContext::IOWorkLoop: skipping cycle due to overload
⚠️ Please check your code before presenting. ⚠️