Widget doesn't work on OS X today

I can’t get my Today widget (or any extension, for that matter) running in the widget simulator. The simulator starts and says “Failed to open widget” along with

Failed to find Widget /Users/SomeUser/Library/Developer/Xcode/DerivedData/Build/Products/Debug/MyApp.app/Contents/PlugIns/MyApp.appex 

I looked in the Console application, and I also see this:

pkd [299]: ignoring an incorrectly configured plug-in in /Users/SomeUser/Library/Developer/Xcode/DerivedData/Build/Products/Debug/MyApp.app/Contents/PlugIns/MyApp.appex: plugins should be isolated from the sand

But this is a sandbox in xcode! It is coded, sandbox and party. Even if I try to deploy it on a new machine (registered as a developer's machine with my developer’s training profile), the widgets do not even appear in the system settings.

Any idea what I need to do?

+8
xcode today-extension macos
source share
3 answers

Well, finally found the problem. I was the code assignment of my application manually (this has never been a problem before), since I had a complex set of frameworks that the application was addressed to, and you had to copy them using the post-build Copy / Runscript script. In any case, it seems that at least Xcode 7 is starting, it no longer works as expected. The application works and indicates that the application was signed correctly, but obviously something is happening behind the scenes that violate the code signature. I ended up deleting all my coding instructions and just used the build step of the Copy Framework column and checked Sign on Copy. Now it works as expected.

+6
source share

I could not stop building and coordinating manually, so I looked into the Xcode build logs and found the difference :) in my case, I just added -fapplication-extension to the compiler and linker flags, now it works!

0
source share

Based on oddities, answer here a slightly more detailed answer:

First select your project and then the purpose of the application (not extension)

enter image description here

Then click Build Phases , then at the top of the Editor window, select Add Build Phase first and finally click Add Copies .

enter image description here

It. Re-create using Widget Simulator and it should work now.

0
source share

All Articles