cordova-plugin-fcm-with-dependecy-updated icon indicating copy to clipboard operation
cordova-plugin-fcm-with-dependecy-updated copied to clipboard

Unable to get notifications on iOS

Open piciuriello opened this issue 4 years ago • 8 comments

Hello. I have notifications working on Android, but not on iOS. I can't understand why. I'm trying the App with TestFlight, the App correctly sends the token, but I still can't get any notification from Firebase test notifications. Also the App didn't asks me the permission to send notifications.

This is my package.json

{
  "name": "XXX",
  "version": "0.0.1",
  "author": "XXX",
  "homepage": "XXX",
  "scripts": {
    "ng": "ng",
    "start": "ng serve",
    "build": "ng build",
    "test": "ng test",
    "lint": "ng lint",
    "e2e": "ng e2e"
  },
  "private": true,
  "dependencies": {
    "@angular/animations": "^11.0.2",
    "@ionic-native/core": "^5.30.0",
    "@ionic-native/device": "^5.30.0",
    "@ionic-native/splash-screen": "^5.30.0",
    "@ionic-native/sqlite": "^5.30.0",
    "@ionic-native/status-bar": "^5.30.0",
    "@ionic/angular": "^5.5.1",
    "bufferutil": "^4.0.2",
    "cordova-plugin-device": "^2.0.3",
    "cordova-plugin-ionic-keyboard": "^2.2.0",
    "cordova-plugin-ionic-webview": "^4.2.1",
    "cordova-plugin-splashscreen": "^5.0.4",
    "cordova-plugin-statusbar": "^2.4.3",
    "cordova-plugin-whitelist": "^1.3.4",
    "cordova-sqlite-storage": "^5.1.0",
    "node-sass": "^4.14.1",
    "rxjs": "~6.5.5",
    "tslib": "^2.0.3",
    "utf-8-validate": "^5.0.3",
    "zone.js": "~0.10.3"
  },
  "devDependencies": {
    "@angular-devkit/architect": "^0.1100.2",
    "@angular-devkit/build-angular": "^0.1100.2",
    "@angular-devkit/core": "^11.0.2",
    "@angular-devkit/schematics": "^11.0.2",
    "@angular/cli": "^11.0.2",
    "@angular/common": "^11.0.2",
    "@angular/compiler": "^11.0.2",
    "@angular/compiler-cli": "^11.0.2",
    "@angular/core": "^11.0.2",
    "@angular/forms": "^11.0.2",
    "@angular/language-service": "~10.0.0",
    "@angular/platform-browser": "^11.0.2",
    "@angular/platform-browser-dynamic": "^11.0.2",
    "@angular/router": "^11.0.2",
    "@ionic/angular-toolkit": "^3.0.0",
    "@types/jasmine": "~3.5.0",
    "@types/jasminewd2": "~2.0.3",
    "@types/node": "^12.19.7",
    "codelyzer": "^6.0.0",
    "cordova-android": "^9.0.0",
    "cordova-ios": "^6.1.1",
    "cordova-plugin-androidx": "^3.0.0",
    "cordova-plugin-androidx-adapter": "^1.1.3",
    "cordova-plugin-fcm-with-dependecy-updated": "^7.7.0",
    "jasmine-core": "~3.5.0",
    "jasmine-spec-reporter": "~5.0.0",
    "karma": "~5.0.0",
    "karma-chrome-launcher": "~3.1.0",
    "karma-coverage-istanbul-reporter": "~3.0.2",
    "karma-jasmine": "~3.3.0",
    "karma-jasmine-html-reporter": "^1.5.0",
    "protractor": "~7.0.0",
    "ts-node": "~8.3.0",
    "tslint": "~6.1.0",
    "typescript": "^4.0.5"
  },
  "description": "Clinica Veterinaria San Gaetanino",
  "cordova": {
    "plugins": {
      "cordova-sqlite-storage": {},
      "cordova-plugin-whitelist": {},
      "cordova-plugin-statusbar": {},
      "cordova-plugin-device": {},
      "cordova-plugin-splashscreen": {},
      "cordova-plugin-ionic-webview": {
        "ANDROID_SUPPORT_ANNOTATIONS_VERSION": "27.+"
      },
      "cordova-plugin-ionic-keyboard": {},
      "cordova-plugin-androidx": {},
      "cordova-plugin-androidx-adapter": {},
      "cordova-plugin-fcm-with-dependecy-updated": {
        "ANDROID_DEFAULT_NOTIFICATION_ICON": "@mipmap/ic_launcher",
        "ANDROID_FCM_VERSION": "21.0.0",
        "ANDROID_FIREBASE_BOM_VERSION": "26.0.0",
        "ANDROID_GOOGLE_SERVICES_VERSION": "4.3.4",
        "ANDROID_GRADLE_TOOLS_VERSION": "4.1.0",
        "IOS_FIREBASE_MESSAGING_VERSION": "~> 7.0.0"
      }
    },
    "platforms": [
      "ios",
      "android"
    ]
  }
}

I also tried to follow this link (https://customersupport.doubledutch.me/hc/en-us/articles/229495568-iOS-How-to-Create-a-Push-Notification-Certificate) but it asks for a user and password and I don't know how to get them.

I'm facing this issue from many days, and I really don't understand how to get rid of it. Can you help me?

piciuriello avatar Feb 17 '21 17:02 piciuriello

I'm also receiving this error. I am successfully generating my token, but IOS does not receive any notifications.

I've also seen that I cannot receive any notifications sent from the FCM Console.

I'm also using 7.7.0.

Does anyone have an idea?

GertVMato avatar Feb 24 '21 06:02 GertVMato

I fixed my bug in this regard. I did not add the permission system for IOS as indicated in the documentation

GertVMato avatar Mar 03 '21 07:03 GertVMato

I fixed the problem calling the function FCM.requestPushPermission(). This should really be clearly stated in section Push Notifications on iOS!

piciuriello avatar Mar 05 '21 20:03 piciuriello

Same problem here, any updates? thanks in davance.

carpiodanielj avatar Sep 15 '21 15:09 carpiodanielj

Did you tried calling the function FCM.requestPushPermission()?

piciuriello avatar Sep 16 '21 06:09 piciuriello

Did you tried calling the function FCM.requestPushPermission()?

hello @piciuriello yes, i tried FCM.requestPushPermission() but still doesn't work

carpiodanielj avatar Sep 16 '21 14:09 carpiodanielj

Same problem here, any updates? thanks in davance.

At development time notifications are working fine in IOS, but not when the app coming from TestFlight. And i don't know why, please help.

carpiodanielj avatar Sep 16 '21 14:09 carpiodanielj

Maybe you have a certificate issue?

Give a look at this article for example: https://fluffy.es/remote-push-notification-testflight-app-store/

piciuriello avatar Sep 17 '21 06:09 piciuriello