在离子应用上,我试图通过Firebase使用cordova-plugin-fcm进行推送通知。 当试图为Android构建我有这个错误:
任务执行失败':CordovaLib:processDebugGoogleServices'。 找不到包名称'org.apache.cordova'
的匹配客户端
我已经阅读了许多具有相同错误的帖子,我理解当google-services.json中的package_name与config.xml中定义的package_name不匹配时会发生这种情况。正确定义我的package_name后,我不知道为什么我会收到此错误,尤其是第二行:
找不到包名称'org.apache.cordova'
的匹配客户端
我不确定,但我认为这行意味着我正在尝试在包名为org.apache.cordova的应用上使用firebase,我是对的吗?
我的google-services.json文件:
{
"project_info": {
"project_number": "746945719967",
"firebase_url": "https://pliiizz-ec46a.firebaseio.com",
"project_id": "pliiizz-ec46a",
"storage_bucket": "pliiizz-ec46a.appspot.com"
},
"client": [
{
"client_info": {
"mobilesdk_app_id": "1:746945719967:android:e3bad7385b3674c5",
"android_client_info": {
"package_name": "com.pliizzbis.usts"
}
},
"oauth_client": [
{
"client_id": "746945719967-9bp7aq8h6i1lsosc3c7dfgqu26plgufl.apps.googleusercontent.com",
"client_type": 3
}
],
"api_key": [ {"current_key": "AIzaSyC5JT3zGpzj1i9eRMTnDkbOveqADYK-Fgw"} ],
"services": {
"analytics_service": {
"status": 1
},
"appinvite_service": {
"status": 1,
"other_platform_oauth_client": []
},
"ads_service": {
"status": 2
}
}
}
],
"configuration_version": "1"
}
我的package_name定义的config.xml文件的第一行:
<?xml version='1.0' encoding='utf-8'?>
<widget id="com.pliizzbis.usts" version="0.0.32" xmlns="http://www.w3.org/ns/widgets" xmlns:cdv="http://cordova.apache.org/ns/1.0\
">