由于应用程序标识符授权,我无法安装watchOS 2 WatchKit应用程序。这发生在打开功能选项卡中的应用程序组之后。

完整的错误:

App安装失败 此应用程序的应用程序标识符授权与已安装应用程序的应用程序标识符授权不匹配。这些值必须匹配才能允许升级。

这是在物理设备上以调试模式运行应用程序。只运行iOS应用程序就可以了。

我再次关闭了应用程序组,并删除了添加的授权文件,但同样的错误。


当前回答

我遇到了这个问题,如果不删除并重新安装应用程序就无法解决这个问题(正如这里的一些人所建议的那样,打乱配置文件并没有帮助)。

但是,我并没有丢失现有的测试数据。对于将来遇到这种问题的人,以下是解决方法:

Before removing the app, open the Xcode "Devices" window (that's cmd-shift-2). Select your device and find your app in the "Installed Apps" list. Click on the gear icon and select "Download Container...". This will copy all of the app's data to your Mac. Save that somewhere for now. Delete the app and reinstall it from Xcode. Kill the app from Xcode (click the stop button), so it's not running. Back in the "Devices" window, click the gear icon and select "Replace Container...". Select the data that you downloaded to your Mac in step 3.

Xcode会恢复你之前保存的应用数据。 现在您已经恢复了旧的测试数据,应用程序应该可以运行了。

其他回答

删除任何以前版本的应用程序从您的iPhone,然后清洁->构建和运行再次。你的应用应该在你的设备上平稳运行。

另外,在尝试直接在设备上运行项目时,请确保您没有在项目设置中选择分发证书。

我有同样的错误,我解决了它通过改变Bundle Identifier的一些新的东西。之后,它建立项目没有任何问题。

我的步骤:

打开Xcode 进入“常规”选项卡 找到身份 将Bundle Identifier更改为新的内容。

这可能是由App ID前缀引起的,当你切换不同的开发者帐户时。请参阅https://developer.apple.com/library/content/technotes/tn2311/_index.html获取Apple的支持。

上面的答案对我都没用。 我的问题是:我从Testflight安装了一个应用版本,所以我删除了旧的应用和Testflight版本,然后它又开始工作了。

我有同样的错误,直到我恢复手表出厂默认https://forums.developer.apple.com/thread/17948

“显然,如果你有一个现有的WatchOS 1应用程序,并试图将其更新到WatchOS 2, bundle标识符会发生变化,并导致这个错误。如果你更新了手表,如果你之前安装了WatchOS1应用程序,那么在更新到WatchOS2之前,你需要重置手表。”