Description:
Please help me, the most of users don't return userId from ids listener and getPermissionSubscriptionState .
getPermissionSubscriptionState return :
{"userSubscriptionEnabled":true,"subscriptionEnabled":false,"notificationsEnabled":true}
Environment
android - RN 0.61 and onesignal 3.5.0
Steps to Reproduce Issue:
Anything else:
i'm searched about any solution but i don't find.
i find a same case on ios and solved on old version of onesignal but i can't install it on RN 0.61
https://github.com/OneSignal/react-native-onesignal/issues/503
@ahyadessam Thanks for the details, we need a bit more information before we investigate.
OneSignal.setLogLevel(6, 0); before OneSignal.init("XXXX"); to enable full logging for OneSignal.Note that the first call to OneSignal.getPermissionSubscriptionState won't result in a userId on the first start of your app if you call it right after init.
However the ids event should be called as soon as the device registers.
1- My RN version is 0.61.4 .
2- all released devices , it's working good on simulator only .
3- i working on android only.
We have noticed this on some Samsung devices, where it fails to get the user/device id with onesignal.
We don't have access to these devices so haven't been able to run the debug logs yet.
Majority of android devices are working as expected + no issues on iOS.
We are running RN 0.61.5 & react-native-onesignal 0.3.5 (although now testing 0.3.6)
Would you be able to use our SetLogLevel method to Verbose and send us the full logcat from the device?
More on this method in the SDK docs: https://documentation.onesignal.com/docs/sdk-reference#section--setloglevel-
If you could send these logs that would be much appreciated and help us better see what is happening in the app.
It's happening with me too with 100% Android 9, 100% Samsung devices and aways in the foreground.
I'm using RN 0.60.4 and Onesignal ^3.4.2.
I trying to catch the logs but for know no success :/
Are any of you experiencing this located in Egypt?
@mikechoch We are not Egypt based.
@brunsy @andrewdazs ,
why can't you include the logcat?
@rgomezp unfortunately we don't have access to any of the problematic devices.
@rgomezp I was not able to reproduce the error in any android simulators or real devices, so nothing appears in my logcat :/
@brunsy , @andrewdazs , are you also seeing this only on Samsung devices running Android 9?
@rgomezp I think we were only seeing this with the Samsung S10+ and Samsung S10e devices.
I'll have some more time to investigate it later this week.
Okay. Please let us know
@rgomezp We faced this on OPPO devices as well,
Also:
unsubscribed in the dashboard and subscriptionEnabled is forever false@mikechoch YES I'M FROM EGYPT
AND ihave the same error
device id is null >>
@A-Tokyo After the user is delete from the OneSignal dashboard I recommend swiping away the app an reopening it to get it to register under a new player / user id on the OneSignal dashboard. Make sure you have the latest SDK as well, there have been some edge cases fixes for this over the last few months.
See my comment above on getting logs if you are still seeing any issue.
https://github.com/OneSignal/react-native-onesignal/issues/909#issuecomment-562376592
On your 2nd point if you uninstall the app and reinstall it you will most likely get a new player / user id so the old will just stay as unsubscribed. Most of the time OneSignal can't tell if it is the same device when the app is reinstalled is why you will we a new record.
Closing due to inactivity
Most helpful comment
@rgomezp We faced this on OPPO devices as well,
Also:
unsubscribedin the dashboard and subscriptionEnabled is forever false