My app gives error when requesting to use Family Controls individual authorization

2022-06-15 13:19:43.606183-0400 App Name Notification test[594:18404] [UIFocus] TtGC7SwiftUI14_UIHostingViewGVS_15ModifiedContentVS_7AnyViewVS_12RootModifier_ implements focusItemsInRect: - caching for linear focus movement is limited as long as this view is on screen.

2022-06-15 13:19:43.677534-0400 App Name Notification test[594:18436] [xpc] Connection error from Optional("com.apple.FamilyControlsAgent"): Couldn’t communicate with a helper application.

 Attempts remaining: 1

Failed to enroll Luis with error: Error Domain=NSCocoaErrorDomain Code=4099 "The connection to service named com.apple.FamilyControlsAgent was invalidated: failed at lookup with error 159 - Sandbox restriction." UserInfo={NSDebugDescription=The connection to service named com.apple.FamilyControlsAgent was invalidated: failed at lookup with error 159 - Sandbox restriction.}

Answered by Jack1886 in 717389022

I found out I need a Provisioning profile "iOS Team Provisioning Profile" there is a way to get without an paid Apple developer account?

Accepted Answer

I found out I need a Provisioning profile "iOS Team Provisioning Profile" there is a way to get without an paid Apple developer account?

I'm having this same error 159, but I actually do already have a team provisioning profile and that's not solving the issue.

How can we get around this error?

Nevermind, I found the solution. You have to go your App's Target > Signing and Capabilities, then add the "Family Controls" capability (even if you're just using family controls for an individual). This will add the necessary entitlement to your entitlements file, and your problems are solved.

My app gives error when requesting to use Family Controls individual authorization
 
 
Q