macOS Widgets won't launch with app group set

i'm working on an app which shares a swiftdata database between the main app and its widgets. prior to the sequoia/xcode 16 betas this was working fine with setting the same app group for app & widget targets.

however, now whenever i try to run my main app from Xcode i get a user permission requestor saying "<app name> would like to access data from other apps.". this happens every time i run it.

whenever the widget is started (via trying to place it on the desktop, or the widgetkit simulator etc) it exits immediately (i assume because it can't show the permission requestor?)

if i disable the app group for the widget, it runs.. however, of course, i can't access the main app's database.

i'm on sequoia beta 2 (24A5279h) and Xcode 16 beta 2 (16A5171r)

note: while the widgetkit simulator is now present in sequoia beta 2, i haven't actually been able to successfully use it

Answered by DTS Engineer in 803903022
it feels like this solution to app groups on macOS could do with a revisit

The app group story on macOS is tricky. I go into gory details in App Groups: macOS vs iOS: Fight!

Two more things:

  • I’ll second Rico’s response up thread. Please file a bug when you encounter stuff that’s causing you grief. And please do post your bug number, just for the record.

  • I’ve been talking to other folks about the multiplatform app problem. See this thread for example.

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

I have almost the same issue. It looks like in Sequoia, you no longer can start your group folder name with group. You have to use your team identifier instead to avoid the dialog you are getting.

Hopefully this is something that gets corrected in future betas as I think it is going to impact a fair number of apps. The RSS reader Unread was also hit with this change. You can read about it on the Golden Hill Software blog.

Our engineering teams need to investigate this issue, as resolution may involve changes to Apple's software. I'd greatly appreciate it if you could open a bug report, include a sample project and sysdiagnose, and post the FB number here once you do.

Bug Reporting: How and Why? has tips on creating your bug report.

Rico
WWDR - Software Engineer

Any news on this? Just updated my mac to and encounter the same problems: widgets arent updated fi.

Accepted Answer

[@Patrick Koning](https://developer.apple.com/forums/profile/Patrick Koning) sorry, i put my "answer" in a comment above - should've done a proper reply and marked it as answered 😅

yes, i did eventually figure it out - the group id for the mac builds needs to have your team id as a prefix (this is new for sequoia) https://developer.apple.com/documentation/xcode/configuring-app-groups#Create-App-Groups-for-macOS-apps

my app was using the Multiplatform project template, and the new group id requirement is not valid for other OS targets... i ended up separating up my app and widget extension targets: macOS and everything else.

i can't imagine the stress/pressure folk at apple have been under as part of this release, so this is meant as a sometime future thing.. but it feels like this solution to app groups on macOS could do with a revisit.. losing the ability to have a single target for multiplatform apps with app groups isn't the end of the world, but for me it's nice to keep it all under one target if at all possible.. 😊

it feels like this solution to app groups on macOS could do with a revisit

The app group story on macOS is tricky. I go into gory details in App Groups: macOS vs iOS: Fight!

Two more things:

  • I’ll second Rico’s response up thread. Please file a bug when you encounter stuff that’s causing you grief. And please do post your bug number, just for the record.

  • I’ve been talking to other folks about the multiplatform app problem. See this thread for example.

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

macOS Widgets won't launch with app group set
 
 
Q