OneSignal / OneSignal-Xamarin-SDK

OneSignal is a free push notification service for mobile apps. This plugin makes it easy to integrate your Xamarin app with OneSignal. https://onesignal.com
Other
105 stars 50 forks source link

Firebase FCM #104

Closed erviem99 closed 5 years ago

erviem99 commented 6 years ago

Description:

I get the following warning with Xamarin and the OneSignal SDK version 3.2.0

[OneSignal] GCM Library detected, please upgrade to Firebase FCM library as GCM is deprecated!

Environment Com.OneSignal SDK version 3.20 on Xamarin Mac (Visual Studio) 7.5.2 and Xamarin.Android 8.3.3.2

Steps to Reproduce Issue: Application Output message when running the app from the debugger

Anything else: Should be fixed in OneSignal 3.9.0.

Nightsd01 commented 6 years ago

The error means what it says. The SDK detects that your app is using GCM (which has been deprecated) instead of FCM.

jkasten2 commented 6 years ago

@erviem99 Sorry for the confusion here, the 3.2.0 nuget spec is still pointing to GCM.

We will update this in a future release to FCM.

erviem99 commented 6 years ago

Thanks, but this is actually pretty serious since:

a) GCM is being deprecated and will be removed in april 2019 b) The reference to GCM prevents us from upgrading Google Play Services

jkasten2 commented 6 years ago

@erviem99 The OneSignal native Android SDK supports both FCM and GCM so it is just a missing dependency in the nuget spec. You can currently add Firebase Message today from nuget and the SDK will use it. You will get a warning about both being included but this won't create any issues. We will be removing GCM and adding FCM in the next update.

a. Correct, the version of the libraries they release on or after April 2019 won't support GCM. However the Google Play services on app on the device will continue supporting the GCM library even after this. Since it is the same IPC binding. b. Do you mean something is preventing an update to the latest Google Play services library now? Or just noted this for the future?

erviem99 commented 6 years ago

It it purely a note for now. In the GCM FAQ it states:

"We will turn off most GCM services in April 2019, so you should plan to have most of your services migrated by then.

Note that client SDKs and GCM tokens will continue to work indefinitely. However, you won't be able to target the latest version of Google Play Services in your Android app unless you migrate to FCM."

https://developers.google.com/cloud-messaging/faq

jzeferino commented 6 years ago

@jkasten2 when should we expect this new release for the FCM?

jkasten2 commented 6 years ago

@jzeferino You can add the Firebase Messaging nuget package today and start testing with it with OneSignal. No code changes are needed for this, the OneSignal SDK will use it automatically.

We don't have a good estimate on the release of the next update, however it will be sometime next month.

jzeferino commented 6 years ago

Ok @jkasten2 thank you. In case of downloading the Firebase Messaging can I remove the GCM package?

jkasten2 commented 6 years ago

@jzeferino It does seem possible to remove through Visual Studio since it is marked as a dependency in the OneSignal nuget spec. The only way I know of to work around it would be do download the .nupkg, modify it, and add the local copy. This isn't necessary to test though as this SDK's logic is to have FCM will override GCM when both are present

nhdanh commented 6 years ago

When new version has release ?

domagojmedo commented 6 years ago

Can we still expect update to be done this month?

zonkzen commented 6 years ago

@Nightsd01 @jkasten2 could you please inform when will you provide a fixed version?

AngeloLazzari commented 6 years ago

hi, i installed the last verision of onesignal xamarin form but it still depends on GCM. if i try to instal it, the compiler says the same of @erviem99, [OneSignal] GCM Library detected, please upgrade to Firebase FCM library as GCM is deprecated! Notification are working correctly ... but we had the message....

So i managed to install Firebase but now i get the following error: illegalargumentexception already added in google/android/gms ....

@jkasten2 can you help us please?

Thank you very much

mcferdev commented 6 years ago

hi, i installed the last verision of onesignal xamarin form but it still depends on GCM. if i try to instal it, the compiler says the same of @erviem99, [OneSignal] GCM Library detected, please upgrade to Firebase FCM library as GCM is deprecated! Notification are working correctly ... but we had the message....

So i managed to install Firebase but now i get the following error: illegalargumentexception already added in google/android/gms ....

@jkasten2 can you help us please?

Thank you very much

I am with the same problem.

rgomezp commented 5 years ago

Closing issue. If anyone is still having issues, please @ me and I will reopen. Thanks

carl-neng commented 5 years ago

Message: W/OneSignal( 6137): GCM Library detected, please upgrade to Firebase FCM library as GCM is deprecated!

After see this message does't see device subscription on onesignal app.

Currently, I have used onesignal nuget 3.2.2 have a problem the same above. And after I have update onesignal version to nuget 3.3.0 it still have the same problem above also. So how to resolve it? Please help...