watchKit fails to run on simulator

1.5k Views Asked by At

I have made required changes for ListerWatchApp to run on simulator [link]. When I run the app it throws an error saying

The shared application group container is unavailable. Check your entitlements and provisioning profiles for this target. Details on proper setup can be found in the PDFs referenced from the README.

Even after changing the code Signing Entitlements.

enter image description here

Here is the link where i have downloaded the example : link

3

There are 3 best solutions below

2
On BEST ANSWER

I was able to run the Lister demo after searching the entire project for 'com.example.apple-samplecode' and replacing that with my own identifier 'com.mycompanyname'. After that I had to go to each target and fix the code signing entitlements plus the capabilities

0
On

So what I have to do is run a grep for all occurrences of com.example.apple-samplecode.Lister, right? I got 7 hits, 2 of which are plist-files:

/ListerOSX/Info.plist /ListerWatch/Info.plist

<proj>/Common/AAPLAppConfiguration.m
<proj>/ListerKit/AAPLCloudListCoordinator.m
<proj>/ListerKit/AAPLDirectoryMonitor.m
<proj>/ListerKit/AAPLListsController.m
<proj>/ListerWatch/AAPLWatchStoryboardConstants.m

Do I have to replace the identifier into one oy my own in

1. all of them 
2. just the plist files
3. or did I get it all wrong?
0
On

After a quick Fix Issue for iCloud and AppGroup in the Targets Capabilties tab everything is fine.
This enables App Groups and iCloud on the App IDs.

App Group