Failed to save complication bundle.

I've been unable to generate a complication bundle for my iOS and Apple Watch app with the latest Xcode 12 Beta 6 version. I consistently get the error in the title with the following:

2020-09-15 16:58:51.203 clockkitutil[3685:143736] generating gallery complication bundle for (null) at /Users/simon/Documents/gallery.ckcomplication

I've tried this on my own project and I've also downloaded the Apple Sample Coffee Tracker WatchKit app which also exhibits the same problems.

Any help or suggestions? Is this a bug?

Replies

Is this a bug?

Appears this complaint has been around for a few years, usually not present when deploying to a device instead of local to your computer.
If you implement the getLocalizableSampleTemplate(for:withHandler:) method in your CLKComplicationDataSource implementation, these sample templates will sync from the watch to the paired phone automatically and be the same across both devices. This is preferred to generating complication bundles to include in your project.

Ok, I do implement the  getLocalizableSampleTemplate(for:withHandler:) method. So should I not ship with any complication bundle at all. I assume there's documentation on this somewhere?

If you implement the getLocalizableSampleTemplate(for:withHandler:) method in your CLKComplicationDataSourceimplementation, these sample templates will sync from the watch to the paired phone automatically and be the same across both devices. This is preferred to generating complication bundles to include in your project.

Are you saying we should no longer be including a complication gallery in our Xcode project? It would be nice if the documentation didn't still tell us to do it the old way: https://developer.apple.com/documentation/clockkit/creating_complications_for_your_watchos_app/adding_placeholders_for_your_complication

Are you saying we should no longer be including a complication gallery in our Xcode project?

That's correct.


Apple Documentation explicitly states:

"if you want your placeholders to appear in the Face Gallery, you must provide a complication bundle that contains your placeholders."

https://developer.apple.com/documentation/clockkit/creating_complications_for_your_watchos_app/adding_placeholders_for_your_complication

Can we please get some further detail here?