OneSignal-Android-SDK icon indicating copy to clipboard operation
OneSignal-Android-SDK copied to clipboard

[Bug]: OneSignal SDK not sending updates for existing Data Tags on any user

Open GreyLabsDev opened this issue 2 years ago • 2 comments

What happened?

OneSignal SDK not sending updates for existing Data Tags on any user

Steps to reproduce?

1. Enable OneSignal for any user, what has no Data Tags on mobile device. Or clean tags for testing user.
2. Through SDK send some test tag for this user - OneSingal.sendTag("TEST_TAG","value_one")
3. Check tag is applied for user in OneSignal console (it's not realtime, but it will be appear in few minutes) 
4. After checking applied tag, send new data for tag with same key - OneSingal.sendTag("TEST_TAG","value_two")
5. Check new tag value is applied for user in OneSignal console
6. Nothing happens. Data Tag has just first value

I found workaround - before sending tag, executing OneSignal.getTags(), and after that OneSingal.sendTag("TEST_TAG","value_two") actually working

In my case I see log for that task for sending new tag data is scheduled in OneSignal SDK, but newer executed

What did you expect to happen?

Expected behavior: After sending new tag data for same key - real Data Tag value is updating on device and in OneSignal console

OneSignal Android SDK version

4.7.3

Android version

12

Specific Android models

Google Pixel 4XL, Android emulator (SDK 31)

Relevant log output

No response

Code of Conduct

  • [X] I agree to follow this project's Code of Conduct

GreyLabsDev avatar Aug 12 '22 12:08 GreyLabsDev

Hi @GreyLabsDev,

Thank you for reporting this issue with clear steps. We will try to reproduce this behavior and follow up.

nan-li avatar Aug 12 '22 16:08 nan-li

Hi, is there any updates about this issue?

GreyLabsDev avatar Aug 30 '22 15:08 GreyLabsDev

Hi @GreyLabsDev,

I am very sorry for the delayed response. I was not able to reproduce. I followed your steps but sending the same key with a new value sets the new value correctly in the device and OneSignal console.

You mentioned using getTags as a workaround, but is the original issue still happening for you?

nan-li avatar Oct 19 '22 06:10 nan-li

Closing for inactivity. Feel free to reopen if this is still an issue

emawby avatar Apr 25 '23 20:04 emawby

@nan-li Anyway thank you for your response! Yes, for moment of your response we used getTags as workaround, but for now we decided to remove tags.

GreyLabsDev avatar Jul 04 '23 13:07 GreyLabsDev