Maurice
Maurice

Reputation: 1464

Today View Extension (Widget) not working

I found several other threads with similar problems, but no one has exactly the same problems.

Besides it DID work some time! the errors now keep occurring while it was working some time before..

When Running my app, that has a build Target "Today View Extension", I get no actual result.

The Extension is shown in Notification Center, but has no body (Simulator AND device).

No body

Also when I try to run the App (not the target extension) and attach the process manually by PID I get this error:

Error on "Attach to Process" (Debug)

I also had the error that my Extension (that has a "Bundle Display Name" entry in Info.plist for a custom Name) did show the Name of the Extension-containing App, and not the string that was set in the Info.plist

Strange thing is that sometimes it worked, sometimes it doesn't, but when it does not there were like five different reasons why not.

I want to ask people who have similar/same problems to post them here to collect all the issues appearing and possibly collect workarounds / solutions for these problems.

Thank you.

Upvotes: 4

Views: 4227

Answers (3)

Maurice
Maurice

Reputation: 1464

For anyone having troubles now:

With beta 4 and beta SDK 4 a lot of bugs were fixed:

 [self setPrefferedContentSize:]

to set the views size is now working properly (if you have troubles viewing your Extension) If your updated Extension is not showing in Notification Center be sure to have a look at the log output, there you can see what task the debugger is attached to, if there is "no Selection" try stopping and running again, it will work after some tries!

If you have questions feel free to ask,

Happy coding

Upvotes: 3

j-techsha
j-techsha

Reputation: 474

I had similar issues. But it seems to be alright now. Since the "Today View" is an extension and is bundled with the containing app, you should just build and run the containing app. From there, you can pull down the "Today View" and if your widget / today view is not added, add it.

You should be able to see all your updated changes without a problem with this and you won't have to attach any process.

Upvotes: 0

UberJason
UberJason

Reputation: 3163

I don't exactly have a solution, but I've observed this happening when anything is "wrong" with my Today extension. For example, if I don't have a file properly targeting the widget. I'm guessing that instead of just crashing to the home screen, iOS just gives you an empty widget? I've written about my own issues here, for reference.

Upvotes: 0

Related Questions