运行离子Cordova运行ios时发生错误-似乎与推送通知有关 [英] Error when running ionic cordova run ios - seems to be related to push notification

查看:109
本文介绍了运行离子Cordova运行ios时发生错误-似乎与推送通知有关的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试在ionic v1项目中测试cordova-plugin-firebase.
运行时出现错误

I am trying to test cordova-plugin-firebase in my ionic v1 project.
I am getting an error when running

ionic cordova run ios 

如果我运行命令

ionic cordova build ios

我没有收到任何错误消息.另外, 如果我在Xcode中打开该项目并尝试在模拟器(iphone 8)中运行该应用程序,则它会成功运行 ,但会在设备上以xcode运行该应用程序(运行的iPhone 4s)也显示相同的错误

I don't get any error message. Also, if I open the project in Xcode and try to run the app in a simulator(iphone 8), it successfully runs but running the app in xcode with a device (iphone 4s) connected also shows the same error when running

ionic cordova run ios.

我收到的错误是自动签名无法解决"nativeApp"目标的权利问题.自动签名无法将aps环境权利添加到您的配置文件中"

The error I am getting is "Automatic signing is unable to resolve an issue with the "nativeApp" target's entitlements. Automatic signing can't add the aps-environment entitlement to your provisioning profile"

我看到解决此问题的方法之一是在目标>功能"下启用推送通知.但是当我在项目导航器中时,似乎无法在Xcode中找到此选项.我目前正在使用XCode 9.1

I saw that one of the solution to this problem is to enable push notification under your "target > capabilities". But I can't seem to find this option in Xcode when I'm in the project navigator. I am currently using XCode 9.1

推荐答案

两者都尝试:-

在代码签名身份"下,将"iPhone分发"更改为用于调试的iPhone开发者"部分. 推送通知:-转到目标->功能,然后打开推送通知.

Under Code Signing Identity, change iPhone Distribution to iPhone Developer for Debug section. push notifications :- go Target-> Capabillities and turned on push notifications.

这篇关于运行离子Cordova运行ios时发生错误-似乎与推送通知有关的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆