Page MenuHomePhabricator

[Bug] Notification number inconsistent on mobile
Open, Needs TriagePublicBUG REPORT

Description

originally reported by @Edtadros in T232011#5522428

Steps to reproduce

Observed on beta cluster

  1. Make an edit
  2. Thank yourself
  3. Notification count goes up by more than one

Also on beta cluster

  1. open notifications
  2. hit browser back button twice
  3. icon is offset

Environments observed

  • Browser version: Chrome
  • OS version: macOS Mojave
  • Device model: iPhoneX, Galaxy S5, iPad Pro, Google Pixel 2, Galaxy Note 3

Check any additional observations

Event Timeline

Restricted Application added a subscriber: Aklapper. · View Herald TranscriptOct 1 2019, 11:13 AM

Just re-checked the following case

Observed on beta cluster

Make an edit
Thank yourself
Notification count goes up by more than one

"thank yourself" is not what's described in the initial report - https://phabricator.wikimedia.org/T232011#5522428 (and it, in fact, is not possible to do). I did not observe the issue "Notification goes up by more than one". In the screenshot in T232011#5522428 the counter displays one unread notification. Were there duplicate 'thank' notifications or there some other messages became un-seen (un-read) when 'thank' notification was received?

Just re-checked the following case

Observed on beta cluster

Make an edit
Thank yourself
Notification count goes up by more than one

"thank yourself" is not what's described in the initial report - https://phabricator.wikimedia.org/T232011#5522428 (and it, in fact, is not possible to do). I did not observe the issue "Notification goes up by more than one". In the screenshot in T232011#5522428 the counter displays one unread notification. Were there duplicate 'thank' notifications or there some other messages became un-seen (un-read) when 'thank' notification was received?

@Edtadros - I think I might have missed something when reporting this. Can you give more detail on the bug?

More testing showed that there is an issue in the way how mobile marks notifications "read" vs how desktop does it.

On desktop, opening the notification flyout on the desktop makes notifications "seen" and the "seen" status will persists until one of the following actions will be happen

  • a notification is clicked
  • or when a notification individually or via "Mark all as read" is clicked (either on the notification flyout or on Special:Notifications page).

On mobile, the message "seen" status is not persistent, e.g.

  • have one notification displayed in the red bell counter
  • click on the bell icon
  • return to the previous page (browser back button or click on the 'x' - the grey number will be displayed (correct)
  • reload a page/navigate to a different page - the counter becomes blank which indicates that notifications are "read" which is not a case.

Now, when a new notification comes, the counter becomes "2" counting the previous unread message. That, what I think, @Edtadros observed. In fact, it's a correct behavior (at least, it is what on the desktop - the previous unread notifications will be counted together with new unseen notifications that just come).

Some additional implications

    • in the above example, when the counter shows "2", open the flyout, close it, the counter on the page will display "1" although both notifications have the same status.
  • on the Notifications overlay, changing the status of individual notifications (marking them "read" or "unread") won't have any effect on the counter.