美文网首页
iOS中多个widget调试时候不桌面不显示小组件

iOS中多个widget调试时候不桌面不显示小组件

作者: waitlonely | 来源:发表于2021-10-20 12:06 被阅读0次

    多个小组件debug时候报错

    SendProcessControlEvent:toPid: encountered an error: Error Domain=com.apple.dt.deviceprocesscontrolservice Code=8 "Failed to show Widget 'com.example.apple-samplecode.Emoji-Rangers.Intermediate' error: Error Domain=SBAvocadoDebuggingControllerErrorDomain Code=2 "Please specify the widget kind in the scheme's Environment Variables using the key '_XCWidgetKind' to be one of: 'EmojiRangerWidget', 'LeaderboardWidget'" UserInfo={NSLocalizedDescription=Please specify the widget kind in the scheme's Environment Variables using the key '_XCWidgetKind' to be one of: 'EmojiRangerWidget', 'LeaderboardWidget'}." UserInfo={NSLocalizedDescription=Failed to show Widget 'com.example.apple-samplecode.Emoji-Rangers.Intermediate' error: Error Domain=SBAvocadoDebuggingControllerErrorDomain Code=2 "Please specify the widget kind in the scheme's Environment Variables using the key '_XCWidgetKind' to be one of: 'EmojiRangerWidget', 'LeaderboardWidget'" UserInfo={NSLocalizedDescription=Please specify the widget kind in the scheme's Environment Variables using the key '_XCWidgetKind' to be one of: 'EmojiRangerWidget', 'LeaderboardWidget'}., NSUnderlyingError=0x7fda3f064360 {Error Domain=SBAvocadoDebuggingControllerErrorDomain Code=2 "Please specify the widget kind in the scheme's Environment Variables using the key '_XCWidgetKind' to be one of: 'EmojiRangerWidget', 'LeaderboardWidget'" UserInfo={NSLocalizedDescription=Please specify the widget kind in the scheme's Environment Variables using the key '_XCWidgetKind' to be one of: 'EmojiRangerWidget', 'LeaderboardWidget'}}}

    XCWidgetKind字段填上任意一个widget名字,否则多个widget找不到具体启动哪一个

    可以参考官网解决方案

    com.apple.dt.deviceprocesscontrols… | Apple Developer Forums

    报错信息

    相关文章

      网友评论

          本文标题:iOS中多个widget调试时候不桌面不显示小组件

          本文链接:https://www.haomeiwen.com/subject/hgktaltx.html