如何在请求苹果之前向我的iOS应用添加权利以快速测试其是否有效

问题描述

我想测试向我的iOS应用添加名为“ MyApp”的权利。例如,可以说以下是权利:

<key>com.apple.developer.networking.gamecenter</key>
    <true/>

我将以上内容添加到我的.entitlements文件中。但是当我这样做时,Xcode开始抱怨说以下错误

Automatic signing is unable to resolve an issue with the "MyApp" target's entitlements.
Automatic signing can't add the com.apple.developer.networking.gamecenter entitlement to your provisioning profile. Switch to manual signing and resolve the issue by downloading a matching provisioning profile from the developer website. Alternatively,to continue using automatic signing,remove this entitlement from your entitlements file and its associated functionality from your code.

我了解错误。它希望我通过进入开发者网站将权利添加到我的配置文件中。但是,甚至在我要求Apple向我授予权利之前,甚至不可能通过添加权利来测试我的代码吗?这真是奇怪。首先,我想测试我的代码,看看添加权利是否对我的应用有效。

解决方法

您不需要在iOS / iPadOS Simulator上进行测试的权利,但对于读取设备,则需要请求该权利。您可以在这里申请:https://developer.apple.com/contact/request/networking-multicast

来源:https://developer.apple.com/news/?id=0oi77447

相关问答

Selenium Web驱动程序和Java。元素在(x,y)点处不可单击。其...
Python-如何使用点“。” 访问字典成员?
Java 字符串是不可变的。到底是什么意思?
Java中的“ final”关键字如何工作?(我仍然可以修改对象。...
“loop:”在Java代码中。这是什么,为什么要编译?
java.lang.ClassNotFoundException:sun.jdbc.odbc.JdbcOdbc...