Rocket.Chat.ReactNative icon indicating copy to clipboard operation
Rocket.Chat.ReactNative copied to clipboard

Message details not shown in push notifications anymore

Open paulchen opened this issue 1 year ago • 52 comments

Description:

The notifications on my Android phone do not show any message details anymore, just the text "You have a new message", despite the server being configured to deliver message details.

Environment Information:

  • Rocket.Chat Server Version: 3.5.3
  • Rocket.Chat App Version: 4.45.0.55377
  • Device Name: ELE-L29 (Huawei P30)
  • OS Version: EMUI 12.0.0 (Android 11)

Steps to reproduce:

  1. Configure the server like this (Workspace -> Settings -> Push -> Privacy):

Clipboard - January 18, 2024 23_19

  1. Wait for a push notification being shown on your mobile phone.

Expected behavior:

The message is shown on the push notification, including its details.

Actual behavior:

The push notification does not contain any message details:

Screenshot_20240118_231842

Additional context:

This issue is quite new, it must have been introduced in one of the most recent versions of the Rocket.Chat server or the app.

paulchen avatar Jan 18 '24 23:01 paulchen

Hey @paulchen, thanks for pointing out the issue

@GleidsonDaniel, can I work on this issue? My approach will be to first verify whether the issue belongs to this repository or the primary mono repo of Rocket.Chat. If this issue is in the app only then I will dive into the notification pushing process and update you with results.

Thanks for your time and consideration Prisha Gupta

preeesha avatar Jan 23 '24 11:01 preeesha

Hey @paulchen, thanks for pointing out the issue

@GleidsonDaniel, can I work on this issue? My approach will be to first verify whether the issue belongs to this repository or the primary mono repo of Rocket.Chat. If this issue is in the app only then I will dive into the notification pushing process and update you with results.

Thanks for your time and consideration Prisha Gupta

I don't recommend working on this issue. The notification flow is a very complex flow, and we are already working on this issue internally.

dnlsilva avatar Jan 23 '24 11:01 dnlsilva

Hey @paulchen, can you find out if this happened after updating the app or the server? Because testing here on some servers, I realized that the problem is intermittent, showing that the problem is not really in the mobile app, because if it were on the mobile it wouldn't work any of the time. On a private server (with very few users) with these same settings it worked 100% of the time.

I'm waiting for more information.

dnlsilva avatar Jan 24 '24 16:01 dnlsilva

Hey @paulchen, can you find out if this happened after updating the app or the server?

I noticed the problem on Jan 19 in the evening. The app on my mobile phone was last updated on Jan 16.

There was no update to the server on Jan 19, but I restarted the instance twice earlier that day (due to updating MongoDB from 6.0.12 to 6.0.13 and later Docker from 24.0.7 to 25.0.0). However, all the messages that triggered the problem were sent at a later time.

Because testing here on some servers, I realized that the problem is intermittent, showing that the problem is not really in the mobile app, because if it were on the mobile it wouldn't work any of the time.

Since I reported the issue, I have received some notifications that worked as expected while others didn't.

On a private server (with very few users) with these same settings it worked 100% of the time.

My instance is a small instance on the Starter plan with 18 registered users.

paulchen avatar Jan 24 '24 21:01 paulchen

similar situation here: updated rocket.chat server (starter) on January 11 from 6.4.0 to 6.5.2 (and mongodb from 4.4.21 to 6.0.12). ios app got updated on January 17 to 4.45.0. all but one (!) push notifications did not show details.

loopway avatar Jan 25 '24 14:01 loopway

similar situation here: updated rocket.chat server (starter) on January 11 from 6.4.0 to 6.5.2 (and mongodb from 4.4.21 to 6.0.12). ios app got updated on January 17 to 4.45.0. all but one (!) push notifications did not show details.

Are you having this error on iOS too? Or is your device Android?

dnlsilva avatar Jan 25 '24 17:01 dnlsilva

https://github.com/RocketChat/Rocket.Chat/issues/31493 - might be the same problem.

loopway avatar Jan 29 '24 20:01 loopway

similar situation here: updated rocket.chat server (starter) on January 11 from 6.4.0 to 6.5.2 (and mongodb from 4.4.21 to 6.0.12). ios app got updated on January 17 to 4.45.0. all but one (!) push notifications did not show details.

Are you having this error on iOS too? Or is your device Android?

I do have the same issue on iOS, both on iPad and iPhone. For me this has started happening once I have signed up for this free preium thing. It’s A self hosted on site instance.

Vaxter avatar Feb 15 '24 10:02 Vaxter

Same problem here. This started from the day we bumped Rocket.Chat Server from version 6.4.X to 6.5.X

matbgn avatar Feb 16 '24 08:02 matbgn

Same. After upgrade to 6.5 notification text disappeared. Any way to debug?

0ki avatar Feb 16 '24 11:02 0ki

FYI we've been investigating this issue.

diegolmello avatar Feb 16 '24 16:02 diegolmello

@paulchen are you also using the Starter plan on your workspace? Or is it running a Pro/Enterprise license? You can check this in Workspace > Administration > Subscription.

matheusbsilva137 avatar Feb 19 '24 16:02 matheusbsilva137

@paulchen are you also using the Starter plan on your workspace? Or is it running a Pro/Enterprise license? You can check this in Workspace > Administration > Subscription.

Starter plan.

However, in the recent days I have not encountered the problem.

paulchen avatar Feb 19 '24 16:02 paulchen

Error still happening on iOS for information

matbgn avatar Feb 20 '24 10:02 matbgn

Just started working today randomly. No update to app, nor the server.

0ki avatar Feb 27 '24 07:02 0ki

Same for me a couple of days ago, but it’s Really random. Some notifications have preview, and some don’t.

Vaxter avatar Feb 27 '24 08:02 Vaxter

I have a possible fix on https://github.com/RocketChat/Rocket.Chat.ReactNative/pull/5596 But I need help testing from all of you, @paulchen @loopway @Vaxter @matbgn @0ki .

Here's the link to TestFlight https://testflight.apple.com/join/3gcYeoMr Build version should be 4.47.0.58428.

Thanks! Let me know if you have any questions.

diegolmello avatar Feb 27 '24 20:02 diegolmello

Here's the link to TestFlight https://testflight.apple.com/join/3gcYeoMr Build version should be 4.47.0.58428.

Unfortunately, I'm unable to use TestFlight.

  • Device Name: ELE-L29 (Huawei P30)
  • OS Version: EMUI 12.0.0 (Android 11)

paulchen avatar Feb 27 '24 20:02 paulchen

@paulchen I wasn't able to reproduce the issue on Android at all. Let me know if it happens again.

diegolmello avatar Feb 27 '24 20:02 diegolmello

Again it happened today. I'm personally on Android, I have a colleague who is on iOS but won't be able to help with TestFlight

matbgn avatar Feb 27 '24 21:02 matbgn

I have a possible fix on https://github.com/RocketChat/Rocket.Chat.ReactNative/pull/5596

But I need help testing from all of you, @paulchen @loopway @Vaxter @matbgn @0ki .

Here's the link to TestFlight https://testflight.apple.com/join/3gcYeoMr

Build version should be 4.47.0.58428.

Thanks!

Let me know if you have any questions.

Installed on all of my devices. I'll give it a run for a couple of days and let you know.

Vaxter avatar Feb 27 '24 21:02 Vaxter

I'd love to test, but the problem has fully disappeared on its own, so I'm afraid I might not be able to verify the fix atm.

0ki avatar Feb 27 '24 23:02 0ki

@paulchen Still happening. Now when phone is unlocked I sometimes can see the sender and content, and when locked still the same. Notifications are set up to show everything even when locked. Same on my iPad.

Vaxter avatar Feb 28 '24 11:02 Vaxter

@Vaxter Thanks for the feedback. It looks exactly what I described on known bugs there, but not only after boot https://github.com/RocketChat/Rocket.Chat.ReactNative/pull/5596

I'll have to investigate deeper. I'm going to let you all know once I have more info.

diegolmello avatar Feb 28 '24 13:02 diegolmello

@Vaxter Try this workaround, but might be tricky to do:

  • Install app from App Store
  • Restart device
  • Receive a push only after device is unlocked
  • App is going to reuse that same valid instance to fetch content

If you do it, let me know if it works forever (or until you restart). That might be what happened to @0ki

diegolmello avatar Feb 28 '24 13:02 diegolmello

@diegolmello also been experiencing this issue since updating to 6.5 around the middle of January. Happens whether my iPhone is locked or unlocked. Updated to 6.6.1 today but problem persists. Installed the TestFlight build.

harryb303 avatar Feb 28 '24 13:02 harryb303

@Vaxter Try this workaround, but might be tricky to do:

* Install app from App Store

* Restart device

* Receive a push only after device is unlocked

* App is going to reuse that same valid instance to fetch content

If you do it, let me know if it works forever (or until you restart). That might be what happened to @0ki

Just tried this, reinstalled the App Store build over the TestFlight build, restarted the phone, unlocked, waited for a push notification and it showed the message content, then locked the phone and received another notification with the message content. Will report back if the issue comes back.

harryb303 avatar Feb 28 '24 14:02 harryb303

Btw there's nothing that proves 6.5 is related to this issue. Our backend team took a look at this last week and couldn't find anything.

On iOS, it's related to how MMKV is handled by iOS when phone is locked (and other behaviors). On Android, I still need to investigate.

If this issue is something that's impacting your use case negatively, you should turn off the setting until we have a fix (or try the workaround above).

diegolmello avatar Feb 28 '24 14:02 diegolmello

I've just updated (due to being forced, I've learned to never trust RC updates because something breaks every single damn time) from 6.4.2 to 6.6.1 and now notifications all of a sudden are missing content so I'd say it'd pretty clearly related to the server version.

ulope avatar Feb 28 '24 14:02 ulope

@ulope Did you have the setting enabled before the update or was it enabled for you afterwards?

diegolmello avatar Feb 28 '24 14:02 diegolmello