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
104 stars 50 forks source link

OneSignal 3.10.3 and Android API 29 #225

Closed excellapay closed 3 years ago

excellapay commented 3 years ago

Description:

I am having an big issue with an app. My Apple version works fine, but on Android, If i compile with API 29 as the target, Users are not getting Push Notifications. On API 27, it works perfect. The issue is that Play Store will not accept anything lower than 29 anymore. It seems like other people are having the issue also, but I cannot find anyone with an upgrade or workaround.

Environment Xamarin and OneSignal 3.10.3

Steps to Reproduce Issue:

  1. (your steps here)

Anything else:

(crash stacktraces, as well as any other information here)

alexkozler commented 3 years ago

A couple people have asked about API 29+/Android X support for Xamarin and they've been pretty dead silent about it. My issue hasn't seen any replies in over 3 weeks.

They pushed out support for native Android X but no commits or any word on anything for Xamarin.Android

excellapay commented 3 years ago

Thanks @alexthekid07 - I think I am about to start playing with Twillio and Azure Notification Hub. Sounds like OneSignal is out of the Xamarin game.

developer9969 commented 3 years ago

Hi very dissapointed if AndroidX or any api 29 is not supported! Can anyone from OneSignal comment on this one?

navio-n commented 3 years ago

Would like to know also... Or to find alternatives?

Jacko1394 commented 3 years ago

I'm waiting for AndroidX support as well. OneSignal is currently unusable in Xamarin projects because Google Play requires apps be built with at least Android SDK API 29 now.

lucas-zimerman commented 3 years ago

Would love to receive any news in regard to Android X support, otherwise, I might be forced to move to another platform :)

excellapay commented 3 years ago

I have tried everything to get a response. We are going live on Azure Notification Hub for all of our apps. There are many aspects where I LIKED Onesignal better, but I this has been a major disappointment. In my mind, they are gone. I do think that with Notification Hub I am getting better 1 to 1 targeting. The Web Interface stinks, but the API is strong and robust.

chrisparkeronline commented 3 years ago

Not sure if this will work as I haven't tried myself, but there are several forks that have been updated. The most recent one is https://github.com/dtaylorus/OneSignal-Xamarin-SDK. Maybe this fork, which appears to have been update 14 days ago with Android libraries updated. I'm going to try in a few days and will let y'all know, please let me know if you try it before I do.

alexkozler commented 3 years ago

@chrisparkeronline did you have any luck with forks?

lucas-zimerman commented 3 years ago

@Jeasmine do you have any ETA to support Android X with OneSignal Xamarin SDK?

developer9969 commented 3 years ago

One signal

come on , it's ridiculous now why dont you reply. what's the plan? Is this repo dead?

jkasten2 commented 3 years ago

We just released Com.OneSignal 3.10.5 with dependency changes to resolve the AndroidX compatibility. Simply upgrade to this version and rebuild your project.

developer9969 commented 3 years ago

@jkasten2 hi there welcome the small update but truly don't get why you didn't remove the support libraries as they are deprecated!!! Would you care to explain? It looks as if there is very minimal effort put on xamarin.

jkasten2 commented 3 years ago

@developer9969 That's a great question! This Xamarin SDK is a wrapper / binding around the OneSignal-Android-SDK 3.x.x. The OneSignal-Android-SDK 4.0.0 has been updated to use AndroidX / Jetpack and was released in Dec 2020. Since this is a major release there is significant breaking API changes that need to be done. Not to just the binding layer but these also need matching public C# your app consumes so this means a major 4.0.0 version of this SDK is needed as well. Lasly a matching OneSignal-iOS-SDK release was made with Android so this needs to be updated as well.

These changes are quite significant and something that would take on the order of months, not weeks to fully complete with testing. The version bumps and the addition of Xamarin.AndroidX.Migration in Com.OneSignal 3.10.5 don't have any negative impact and resolve all the compatibility issues today in the short term.

lucas-zimerman commented 3 years ago

@jkasten2 hi there welcome the small update but truly don't get why you didn't remove the support libraries as they are deprecated!!! Would you care to explain? It looks as if there is very minimal effort put on Xamarin.

OneSignal uses Android Support and not AndroidX. They are using Android Migration so that on code behind the Support bindings is redirected to AndroidX callback and at the end, Android Support packages are removed.

It's what it's, at least it doesn't block users from upgrading their apps to Android 10 or newer.

developer9969 commented 3 years ago

@jkasten2 first really appreciate your reply, replies by One signal on this thread is rare....

one thing to note though that the AndroidX Migration under the covers it will do it's best to match the existing Android.Support to it's equivalent AndroidX libraries and replace them but from my reading I remember that was not guaranteed.

Whilst I appreaciate the impact of removing the Support libraries , is one of those job that should be done. We spent 2 weeks upgrading and remove all the support libraries from our apps.

I sincerely hope that you have a roadmap in place for the support libraries to be dropped. It was the assumption that all these waiting months was to actually remove those rather than quickly add the Xamarin.AndroidX.Migration as a silver bullet.

jkasten2 commented 3 years ago

one thing to note though that the AndroidX Migration under the covers it will do it's best to match the existing Android.Support to it's equivalent AndroidX libraries and replace them but from my reading I remember that was not guaranteed.

I believe this depends on:

  1. One-to-one APIs in Android Support Library 28 being available in AndroidX.
  2. The tool (Xamarin.AndroidX.Migration) to be able to correctly map this.
    • I can't speak to how Xamarin implemented this migration library but I would guess it either uses Google's Jetifier under the hood or it's own implementation which is very close. For our Android Native customers using OneSignal-Android-SDK 3.x.x Jetifier hasn't had any issues.

I sincerely hope that you have a roadmap in place for the support libraries to be dropped. It was the assumption that all these waiting months was to actually remove those rather than quickly add the Xamarin.AndroidX.Migration as a silver bullet.

For the OneSignal-Xamarin-SDK 4.0.0 release moving to AndroidX will be part of it. As noted in https://github.com/OneSignal/OneSignal-Xamarin-SDK/issues/225#issuecomment-814504398 this is months away (I don't have a better ETA at this time) as it includes upgrading to the new OneSignal-Android-SDK 4.0.0 API and matching iOS API as well.

developer9969 commented 3 years ago

@jkasten2 thank you for your replies. Looking forward to OneSignal-Xamarin-SDK 4.0.0