iossimulatorwatchkitapple-watchxcode6.3

Xcode 6.3 + trying to run the Watch App in simulator results in "FBSOpenApplicationErrorDomain error 4"


I am writing a Watch App for one of my applications. Since my team don't have an Apple Watch yet, I build a Simulator version of my application as well on my build server for my QA team and they are using "xcrun simctl" to run and test the watch app itself.

Everything went well until Xcode 6.3 came. With Xcode 6.3 I received this error when I've tried to build the app locally on my development machine :

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.492). These values are required to match.

To fix this issue, I've modified my info.plist files to contain the same CFBundleVersion. This modification fixed the build issue on my local development machine, but : QA is still able to run the iOS application, but launching the Watch App fails with this error :

> xcrun simctl launch 0D5238ED-CBE9-4DCC-961D-BC756E0885CD com.company.enterprise.appname.watchapp
An error was encountered processing the command (code=4):
The operation couldn’t be completed. (FBSOpenApplicationErrorDomain error 4.)

I can't see anything in the system console log which could be related to this. :/

Do you know any ideai how could this issue be solved?

Thanks in advance for any help!


Solution

  • I turned out that adding CFBundleGetInfoString to the watchKit Extension/watchKitApp caused the issue for me (it is OK to have it in the companion iOS app itself). Removing that solved the issue for me.

    defaults delete `pwd`/myApp WatchKit Extension/Info CFBundleGetInfoString
    defaults delete `pwd`/myApp WatchKit App/Info CFBundleGetInfoString