我在 xcode 日志中得到了这个:
[_UIRemoteKeyboards proxy]_block_invoke Failed to access remote service: Error Domain=NSCocoaErrorDomain Code=4099 "The connection to service named com.apple.UIKit.KeyboardManagement.hosted was invalidated from this process." UserInfo={NSDebugDescription=The connection to service named com.apple.UIKit.KeyboardManagement.hosted was invalidated from this process.}
知道是什么原因造成的吗?
最佳答案
此错误可能是因为您的键盘需要完全访问权限。
从键盘目标打开 info.plist。
为键设置值是
RequestsOpenAccess
您还可以通过以下方法确保您的键盘扩展具有完全访问权限
func hasOpenAccess() -> Bool {
UIPasteboard.general.string = "TEST"
return UIPasteboard.general.hasStrings
}
关于ios - 应用程序激活时出错,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/57161223/