When I open my existing Watchkit app (Xcode 6.2), it compiles correctly, the simulators are launched (iPhone+Watch), followed by the meaningful error:
Error Launching 'xxx Watchkit Extension'
SPErrorInValidBundleNoGizmoBinaryMessage
I have this issue with all simulators (iPhone 5/5S/6/6+ - 38mm/42mm)
Any ideas what the issue can be?
It seems for some reason the application does not want to run on the simulator, even though it used to. The iPhone application included in the same project does run, as do other Watchkit sample applications.
Did you change the bundle ID of your app? If so you may need to manually update the WKAppBundleIdentifier in the WatchKit Extension and also the WKCompanionAppBundleIdentifier in the WatchKit App.
WKAppBundleIdentifier may need to be same to WatchKit App's Bundle Identifier.
Please check WatchKit Extension's info.plist.
NSExtension - NSExtensionAttributes - WKAppBundleIdentifier - xxxxx.watchkitapp
EDIT: Further explanation to clarify...
Under your App target you go to INFO tab and set Bundle Identifier to com.myapp
Then under the WatchKit Extension target you go to INFO tab and set the Bundle Identifier to com.myapp.watchkitextension
Then still under the WatchKit Extension target and still under the INFO tab you set NSExtension > NSExtensionAttributes > WKAppBundleIdentifier to com.myapp.watchkitapp
So one ends with .watchkitextension and the other ends with .watchkitapp
Check Info.plist for "Your App WatchKit Extension" & "Your App WatchKit App". First part of all indentifiers should be same.
In my case problem was in "Your App WatchKit Extension" > NSExtension > NSExtensionAttributes > WKAppBundleIdentifier.
Be sure you are using an 8.3 simulator.
I got this message consistently when using 8.2. Tried everything listed here and struggled with this for hours. Switching to 8.3 resolved it. Ironic, since you must set the deployment target to 8.2 at the moment, but watchkit apps need 8.3 to run I guess...
I checked all bundle identifiers multiple times but couldn't get rid of the issue. Neither did cleaning the build folder work out.
However, I was able to sort it out by turning off Game Center at the Capabilities of my WatchKit Extension.
Turning it on for the iOS host app seems to work fine, but turning it on for the WatchKit Extension results in the SPErrorInvalidBundleNoGizmoBinaryMessage error when attempting to run the WatchKit App in the simulator, while it completes building without any complaints.
I'm developing a game for Apple Watch and was looking forward to support Game Center. It was actually my plan from the very beginning to communicate with the hosting iOS app to do so, but then I saw Game Center listed in the Capabilities of the WatchKit Extension itself, so I expected to be able to deal with it right there. However, as it doesn't seem to work, I'm going to stick to my original plan to support it through the hosting iOS app.
Xcode Version 6.2 (6C131e)
EDIT: Same issue with Xcode Version 6.3 (6D570)
For issues on real devices (not simulator), do everything in this post:
http://blog.jaredsinclair.com/post/117350678170/jareds-code-signing-tips-apple-watch-edition
Most importantly:
All three targets require the following:
a unique app ID for that target a code signing identity (applies to
all targets) a unique provisioning profile for that target.
and make sure that the app ID's are consistent:
Your app IDs will look something like this:
com.company.App-Name
com.company.App-Name.todaywidget
com.company.App-Name.watchkitapp
com.company.App-Name.watchkitextension
If it still doesn't work, manually delete the app from the watch (by holding onto the icon and then hit 'x') and then try again. This was the kicker that did it for me.
The procedure I solved the problem is
Check if WKAppBundleIdentifier and bundle identifier in WatchKit extension and WatchKit App are correct
Delete subfolders of ~/Library/Developer/CoreSimulator/Devices
Delete subfolders of ~/Library/Developer/Xcode/DerivedData
Clean my project
Restart simulator
Run
I've been struggling with this as well. This is what solved my problem on Xcode 7.1 iOS 9.
Just Make sure you follow the naming below for your identifiers:
Target - com.myCompany.myApp
Watchkit app - com.myCompany.myApp.watchkitApp
Watchkit extension -
com.myCompany.myApp.watchkitApp.watchkitextension
The extension should have the identifier of the WatchKit app target + .watchkitextension
I've tried everything posted thus far in this thread but still couldn't get it to work. I resorted to backtrack to the point when it was working and retrace every single action that I've done to figure out at which point it breaks...
As it turned out, the WatchKit App's info.plist file does not like any custom plist entry, at least that is what I've found out in my case. I've added an entry called "MyAppBundlePrefix" and it caused the "Error Launching 'xxx Watchkit Extension' SPErrorInValidBundleNoGizmoBinaryMessage"
I wish XCode would offer a little bit more specific detail for that error but it took me about 5 hours to find it out by brute force way.
Related
There are several posts on this issue but none of the proposed solutions work in my case. I am trying to integrate the WatchKit into a simple, sample app (I've tried a couple now) by following the instructions provided by Apple. When I compile I get the following error message:
"error: WatchKit Extension doesn't contain any WatchKit apps. Verify
that the value of WKWatchKitApp in your WatchKit App's Info.plist is
set to YES."
I have successfully compiled and run the Apple Watch "Catalog" example so I know things are working from an iPhone to Watch perspective. It seems like something is not right when I try to integrate with an existing app.
I have seen the posts here on this topic (e.g. WatchKit app wont run on simulator) but none of the fixes work in my case; the bundle IDs all appear to be correct. Note I am trying to compile and run on an iPhone 6 not on the simulator.
Any suggestions?
This error occurred for me when I changed the bundle id of my main iOS App.
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 the error for me.
I ran into this problem on XCode Version 10.2 (10E125), i realizes when i changed WatchkitApp Bundle identifier one key in watchkitapp extension did not changed and stayed as old bundle identifier.
the path to plist: /Users/.../YourXcodeProjectFolder/Project/YourWatchkitExtensionFolder/info.plist
the problem occurd 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 key WKAppBundleIdentifier was made the problem, so i changed it by my self.
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 any string different from current string. Agreed that it is a bizarre solution as called 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/
Main reasons to this error,
1 Incorrect watch app bundle id in watchkit extension plist file.
Missing dependancy of watchapp.app in watchkit extension target.
Apple document with catalag example may help
https://developer.apple.com/library/ios/technotes/tn2410/_index.html
Below settings worked for me
In Main App Info.plist
Bundle identifier:com.domain.WatchKit-table
In Watchkit App Info.plist
WKCompanionAppBundleIdentifier:com.domain.WatchKit-table
Bundle identifier:com.domain.WatchKit-table.watchkitapp
WatchKit Extension Info.plist
NSExtension>NSExtensionAttributes>WKAppBundleIdentifier:com.domain.WatchKit-table.watchkitapp
Bundle identifier:com.domain.WatchKit-table.watchkitapp.watchkitextension
Note: my bundle id has * as the third component.
WatchKit-table is my project name
I noticed this with xcode 10.0 after changing the build number.
Cleaning the build folder, closing xcode, and re-opening worked for me.
In my case I had problem with building of the extension library. In fact it was not built and I had two errors:
1. From linker about absense of the extension library.
2. From Xcode about "missing" NSExtensionPointIdentifier key.
Fix of linking error also fixed this message.
I'm using Xamarin and Visual Studio (on the PC). I had this issue, but none of the fixes above worked. Much like the XCode fix, however, restarting Visual Studio turned out to be the answer. /sigh
My watchkit app extension has suddenly stopped launching. I have a breakpoint in (void)awakeWithContext:(id)context, but that does not get called.
I am running the WatchKit app extension, and all the certificates are in order. I have a 42mm screen set as the external hardware display. I have tried re-starting XCode.
I had during the course of development cleared my DerviedData. This removes the WatchKit extension from the list of embedded binaries in the app. To fix this, you have to
1. Rebuild the project.
2. Click on Add Embedded Binaries, select the "App Name WatchKit extension.appex" file.
This solved the problem for me.
I'm trying to develop an extension of my app for the Apple Watch.
Instead of install the app on the watch, I have this error:
AppName Failed to install AppName, error: Invalid Bundle - No Apple Watch Binary
In my info.plist files...
For the extension, I have:
<key>CFBundleIdentifier</key>
<string>com.mycompany.AppName.watchkitextension</string>
<key>WKAppBundleIdentifier</key>
<string>com.mycompany.AppName.watchkitapp</string>
For the WatchKit app, I have:
<key>CFBundleIdentifier</key
<string>com.mycompany.AppName.watchkitapp</string>
<key>WKCompanionAppBundleIdentifier</key>
<string>com.mycompany.AppName</string>
And for my app, I have:
<key>CFBundleIdentifier</key>
<string>com.mycompany.AppName</string>
Did I miss something?
This error plagued me for about 7 hours then I restarted my watch out of desperation and the error went away.
I was plagued with this error for hours. For me, the problem was that my WatchKit Extension's Deployment Target was set to an iOS version higher than my phone's. I simply changed it to match my device's version and it worked perfectly.
For me the problem was fixed by adding the watch app to my iOS target's Embed Watch Content section.
I'm using Xcode 7 and watchOS 2.0. It was building fine on the device, but the simulator was giving me this error.
Steps:
Find your iOS target
Click Build Phases
Ensure your watch app (.app) is included in "Target Dependencies" and "Embed Watch Content"
Try explicitly setting the "Executable file" in the WatchKit app's info.plist.
I had changed the name of my executable file and had the same issue.
In my case, none of these solutions worked for me, however I noticed that by default, my WatchKit App required iOS 8.3, and my phone was running iOS 8.2. Updating the OS to 8.3 solved my problem. It may seem like an obvious solution, but I thought I would share for anyone who could share my problem.
In my case, I got it when building app for WatchOS2. I fixed by setting the schemes like this:
The Watch Extension Scheme builds
3 Target: iPhone (2 dependencies) + Extension (no dependencies) + Watch App
Running Extension Scheme on iPhone simulator -> works!
In my case it was an Info.plist configuration error. The Bundle identifier was different to the NSExtension -> NSExtensionAttributes -> WKAppBundleIdentifier.
Setting the same value fixed the error.
Resets of watch/xcode/iphone doesn't help sometimes, as it described in other answer.
One more case to solve this:
This error appears, when I change iPhone language of my iPhone to not English (in my case - Russian) language.
When I set back English - everything start works as usual!
Make sure:
The bundle id of iOS app is prefix of watch app & extension' bundle id.
Value of WKCompanionAppBundleIdentifier in Info.plist of your watch app matches bundle id of your iOS app.
iOS app, watch app & extension should signed by the same cert.
There must be a build phase in iOS app target:
Destination: Products Directory
Subpath: $(CONTENTS_FOLDER_PATH)/Watch
Click +, add your watch app target.
Filling in the Bundle Display name in the info.plist.Default is blank,there will be an alert.(Xcode 7.3)
Planning for watch kit integration
error: The value of CFBundleVersion in your WatchKit app's Info.plist (1) does not match the value in your companion app's Info.plist (2.0). These values are required to match.
Struck with above error.
- changed the deployment targets of both notification & watchkit app. But build failed
Thanks.
You need to make sure that the CFBundleVersion in the Info.plist of your WatchKit App is identical to the CFBundleVersion in your parent app’s Info.plist.
For those of you who struggling with adapting your build autonumbering scripts (like this one) to WatchKit and getting the same dreaded The value of CFBundleVersion in your WatchKit app's Info.plist ... does not match the value in your companion app's Info.plist ... error, here is the solution: set Strip Debug Symbols During Copy to No for the project, remove same option overrides for all targets, make clean (Cmd+Shift+K) and build (Cmd+B).
Disclaimer: this is more hack than a solution, I don't know why it works, but it's the only way I got my autonumbering script working with WatchKit and I think this information would be useful for someone. If you have better ideas, please share.
Update: finally found a real solution. Turns out even without UI one could easily add a run script to WatchKit App target by manually editing project.pbxproj. Thank you, Curtis Herbert!
error: The value of CFBundleVersion in your WatchKit app's Info.plist (14) does not match the value in your companion app's Info.plist (13). These values are required to match.
I finally figured out the problem is the value of my companion app 's Info.plist which equals to 13, is not equal to that value in WatchKit App.
So you have to make sure that the Bundle version panel 's value in each Info.plist is matched.
After installing WatchKit application extension.There was conflict in
Bundle versions string, short && Bundle version .
So Update both of Keys to values which are equals in both the Extension and main app targets in info.plist file .
&&
When ever you get such problems after updating build number or version. Please follow the steps, which worked for me :
Clean the project
Try to run the project in any one of the simulators
Build or Archive
welcome to the party. I was able to work through this by editing the Info.plist ion both Watchkit App and Watchkit Extension, and then editing the marketing version in the AppName(root level)/Targets/AppName/Versioning/Marketing Version.
Hope this helps anyone else that comes across this issue.
I got this error when I create new target watch kit with different team selected by default while creating the watch app for ios app so i just deleted the targets and again add with same team as my project.
I am trying to debug and run the app on apple watch simulator. I have tried by using different target for notification, Glance and Watch app but apple simulator don't shows any thing.. It stuck in waiting for attach process of extension. I just see a black screen for the Apple Watch Simulator.
What did I do wrong?
How to overcome this issue ?
This post from the dev forums solved my issue. More specifically, this excerpt:
In order for Watch apps to function properly, certain properties
must match across the Watch app and its App Extension (18857540):
The WKAppBundleIdentifier property of NSExtensionAttributes in the WatchKit App Extension’s Info.plist must match the
CFBundleIdentifier of WatchKit App's Info.plist.
The WKCompanionAppBundleIdentifier property of the WatchKit App's Info.plist must match the CFBundleIdentifier of the Containing iOS App's Info.plist.
I have exactly same problem. I created a new project and added WatchKit extension in Xcode 6.2 beta 4 with WatchKit. I tried all ways mentioned in other answers but still failed to let watch app run in the simulator. Finally, I made it work.
My steps:
Delete the containing app in the iPhone simulator.
Clean your project in Xcode.
Do not run the containing app, run the WatchKit app from Xcode.
I had the same issue. The only thing that helped was to delete and recreate the target scheme.
Before spending a lot of time on changing things, restart Xcode. Sometimes, this solves the problem.
Even if everything is configured correctly, it may take 20 seconds to attach the process to the debugger.
You need to run the Watch App target and then from iPhone/iPad simulator check (Hardware -> External displays), any one of the Apple Watch options.
I was experiencing the same issue. Mainly when creating an app extension in an existing app.
I was able to consistenly solve it by doing the following steps:
Make sure that the app extension gets the .appex extension. XCode tends to set it to .app. You can do this under 'build settings' -> 'wrapper'.
Under the 'Build Phases' tab in your target, your app extension should be listed under 'Embed App Extensions'. If you don't see this section, you can enforce it by adding a normal app extension to your app (fe. action extension). The section will now be visible. Replace the dummy extension you just created with the Watch app extension.
Start the host app and then start the Watch app, it should be working now.
I had some trouble on iPhone 6 simulator, but each time I switch on iPhone5S it works.
In my case the trouble was caused by a scheme with missing target although not the one I was trying to run.
Hope that helps somebody.
I was running into this problem as well and tried a few of the suggestions above. I found that deleting and recreating the target scheme resolved it. Everything is working fine now.