xcode 在步骤中报错:将推送通知功能添加到您的 App ID

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/41220355/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-09-15 09:39:39  来源:igfitidea点击:

Report error in Step:Add the Push Notifications feature to your App ID

iosxcodeapple-push-notifications

提问by aircraft

In developer website , I make my app ID's Push Notificationsenable.

开发者网站上,我启用了我app IDPush Notifications

But in my project,TARGETS-> Capabilities-> Push Notifications-> I want to open it, but after sometime, there report errorin

但是,在我的项目,TARGETS- > Capabilities- > Push Notifications- >我想打开它,但一段时间后,有报道error

Step:Add the Push Notifications feature to your App ID

步骤:将推送通知功能添加到您的 App ID

The picture I token:

我标记的图片:

tHE

这

Additional info is: I use Xcode 8, iOS 10

附加信息是:我使用Xcode 8iOS 10



Edit -1

编辑-1

In my Signing, there is error:

在我的Signing,有错误:

enter image description here

在此处输入图片说明



Attempt - 1

尝试 - 1

I have restart my Xcode 8, and it does not work for me.

我已经重新启动了我的Xcode 8,它对我不起作用。

回答by Mel

This problem occurred to me when moving from XCode 7 to XCode 8. To resolve this, I had to disable Push Notifications and re-enable them. Then I had to make sure that in Build Settings the Code Signing Identity and the Provisioning Profile were configured correctly with the account and provisioning profile associted to the AppID that have de Push Notifications enabled.

从 XCode 7 迁移到 XCode 8 时,我遇到了这个问题。为了解决这个问题,我不得不禁用推送通知并重新启用它们。然后我必须确保在构建设置中,代码签名身份和配置文件配置正确,帐户和配置文件关联到启用了推送通知的 AppID。

回答by Hosny

I think you enabled push notification in app ID but you didn't create provisioning profile for this app ID so Xcode select provisioning profile automatically and that provisioning file not support push notification capability , so try to create provisioning profile for this app ID and download it then double click on it to listen in Xcode try to restart Xcode , hope this help you .

我认为您在应用程序 ID 中启用了推送通知,但您没有为此应用程序 ID 创建配置文件,因此 Xcode 自动选择配置文件并且该配置文件不支持推送通知功能,因此请尝试为此应用程序 ID 创建配置文件并下载它然后双击它在Xcode中收听尝试重新启动Xcode,希望这对您有所帮助。