WatchKit application will not compile: "error: WatchKit Extension does not contain any WatchKit applications"

There are several posts on this subject, but none of the proposed solutions work in my case. I am trying to integrate WatchKit into a simple sample application (I tried a couple now) following Apple's instructions. When I compile, I get the following error message:

": WatchKit Extension does not contain any WatchKit applications. That the WKWatchKitApp value in your WatchKit App.plist application is set to" YES ".

I successfully compiled and ran the Apple Watch Directory example, so I know that everything works with the iPhone to view perspective. Something seems to be wrong when I try to integrate with an existing application. I saw posts here on this topic (for example, the WatchKit application does not start on the simulator ), but none of the fixes work in my case; all packet identifiers look correct. Note. I am trying to compile and run on an iPhone 6 not on a simulator. Any suggestions?

+9
ios objective-c iphone apple-watch
source share
7 answers

This error occurred to me when I changed the package id of my main iOS application. This is what I did in the project explorer

  • Under WatchApp -> plist

    WKCompanionAppBundleIdentifier ==> Give the id of the iOS App (com.xxxx.appname)

  • Under WatchApp Extension β†’ plist NSExtension-->NSExtensionAttributes-->WKAppBundleIdentifier ==> Give the id of your watchkit app (eg: com.xxxx.appname.watchkitapp)

this fixed a bug for me.

+24
source share

The main causes of this error,

1 Incorrect application package identifier for viewing in the plist file of the watchkit extensions.

  1. There is no watchapp.app dependency in the watchkit destination.

Apple document with directory can help https://developer.apple.com/library/ios/technotes/tn2410/_index.html

+3
source share

I noticed this on Xcode version 8.2.1. Here is how I fixed it.

Go to β€œWatchKit App” β†’ Build Settings β†’ Packaging β†’ Product Name

Change it so that any line differs from the current one. I agreed that this is a bizarre decision, as indicated in the link below.

Source: https://blogofpuneet.wordpress.com/2015/05/02/xcode-build-error-watchkit-extension-doesnt-contain-any-watchkit-apps-verify-that-the-value-of-wkwatchkitapp- in-your-watchkit-apps-info-plist-is-set-to-yes /

+3
source share

The settings below worked for me

  • In the main App Info.plist

Package ID: com.domain.WatchKit-table

  • In Watchkit App Info.plist

WKCompanionAppBundleIdentifier: com.domain.WatchKit table

Package ID: com.domain.WatchKit table. watchkitapp

  • WatchKit Extension Info.plist

NSExtension> NSExtensionAttributes> WKAppBundleIdentifier: com.domain.WatchKit-table.watchkitapp

Package ID: com.domain.WatchKit table. watchkitapp.watchkitextension

Note: my package id has * as the third component. WatchKit table is my project name

+2
source share

I noticed this with xcode 10.0 after changing the build number.

Clearing the build folder, closing xcode and reopening helped me.

+1
source share

In my case, I had a problem creating an extension library. In fact, it was not built, and I had two errors: 1. From the linker about the lack of an extension library. 2. From Xcode about the "missing" key NSExtensionPointIdentifier.

Binding bug fixes also fixed this message.

0
source share

I encountered this problem in XCode Version 10.2 (10E125) , I have XCode Version 10.2 (10E125) that when I changed the identifier of the WatchkitApp package, one key in the watchkitapp extension did not change and remained the same package identifier.

list path: /Users/.../YourXcodeProjectFolder/Project/YourWatchkitExtensionFolder/info.plist

The problem arose here:

 <key>NSExtension</key> <dict> <key>NSExtensionAttributes</key> <dict> <key>WKAppBundleIdentifier</key> <string>com.applecode.water.watchkit</string> </dict> <key>NSExtensionPointIdentifier</key> <string>com.apple.watchkit</string> </dict> 

The WKAppBundleIdentifier key was made a problem, so I changed it myself.

0
source share

All Articles