WidgetEntryPointFactory' does not conform to `NonUIEntryPoint` when previewing watch widget

Following the sample notes at https://developer.apple.com/documentation/widgetkit/creating-lock-screen-widgets-and-watch-complications, when I try to preview the Watch widget, I get an error saying: Cannot preview in this file WidgetEntryPointFactory' does not conform to NonUIEntryPoint


RemoteHumanReadableError: Type 'WidgetEntryPointFactory' does not conform to NonUIEntryPoint (in framework at path /System/Library/PrivateFrameworks/ChronoCore.framework/Support/WidgetPreviewsExtensionAgent.bundle)

==================================

|  MessageSendFailure: Message send failure for <ServiceMessage 187: update>

App widgets preview fine though.

Am I doing something obviously wrong?

This happens for me, too, though I can't preview any widgets at all regardless of platform. I think this might be an internal problem with Xcode 14 Beta 1.

Hi,

Sorry to hear you are having problems getting widget previews working.

This sounds like an issue we are already tracking, but to help verify could you try this workaround and see if it gets the widget previews working?

1 Run:

mv ~/Library/Developer/CoreSimulator/Caches/dyld{,_old} ; sudo killall -9 com.apple.CoreSimulator.CoreSimulatorService

2 Attempt to load the preview again.

Thanks for the quick turnaround. I can confirm that worked, so you're definitely on the right track.

For others who need this in the interim, the command above only works once - mv fails if the target folder already exists, which happens if you run this command more than once. Here's a version of it that does some cleanup at the beginning, so you can just run the command whenever there's an issue:

rm -r ~/Library/Developer/CoreSimulator/Caches/dyld_old ; mv ~/Library/Developer/CoreSimulator/Caches/dyld{,_old} ; sudo killall -9 com.apple.CoreSimulator.CoreSimulatorService

Yes indeed that worked for me too. Thanks!

I stumbled on this issue as well today in Xcode Version 14.0 beta 3 (14A5270f) . The workaround does work but it only lasts for a very short time. When I add another preview variant it breaks again.

In Xcode 14 beta 3, create a watch only app, create a widget extension:

RemoteHumanReadableError: Type 'WidgetEntryPointFactory' does not conform to NonUIEntryPoint (in framework at path /System/Library/PrivateFrameworks/ChronoCore.framework/Support/WidgetPreviewsExtensionAgent.bundle)

==================================

|  MessageSendFailure: Message send failure for <ServiceMessage 43: update>

Thanks for all the reports. We have identified an additional case of this issue that was not fixed as part of beta 3. We are actively investigating more fixes to hopefully fully eliminate the issues y'all are hitting.

I'm on Xcode 14 beta 4.

I created a new empty watch only app and then a widgets extension. I see the build error that yvsong mentions above. Then I run the terminal command that colejd recommends and that removes the build error.

But I still don't see a widget preview, I just see a black rectangle.

I tried changing the text color and removing the date formatting and just making it a string, I still just see the rectangle.

I love this new combined framework so much. Can't wait to build some cool stuff with it.

WidgetEntryPointFactory' does not conform to `NonUIEntryPoint` when previewing watch widget
 
 
Q