Game Center doesn't work on Mac Catalyst app via TestFlight due to sandbox error.

Following the advice here:

https://developer.apple.com/documentation/gamekit/enabling_and_configuring_game_center

I tried allowing incoming connections in addition to outgoing connections but it doesn't help.

I get this error:

Could not get services from gamed. Please file a radar including GameKit logs, and any gamed crash logs. ERROR Error Domain=NSCocoaErrorDomain Code=4099 "The connection to service named com.apple.gamed was invalidated: failed at lookup with error 159 - Sandbox restriction." UserInfo={NSDebugDescription=The connection to service named com.apple.gamed was invalidated: failed at lookup with error 159 - Sandbox restriction.}

This happens on macOS 12.6.1.

What am I doing wrong? Is there a workaround?

Game Center doesn't work on Mac Catalyst app via TestFlight due to sandbox error.
 
 
Q