Skip to content
This repository has been archived by the owner on Apr 26, 2024. It is now read-only.

Badges for rooms without notifications #2270

Closed
zzottel opened this issue Jun 9, 2017 · 7 comments
Closed

Badges for rooms without notifications #2270

zzottel opened this issue Jun 9, 2017 · 7 comments

Comments

@zzottel
Copy link

zzottel commented Jun 9, 2017

I have two rooms that are set to notify only when I'm mentioned. This works, i.e. I only get desktop/mobile notifications when I'm mentioned.

However, whenever there are new messages in these rooms, the window title in Riot Web gets an unread rooms badge ("Riot [1]"), and Riot Android gets a badge shown on the home screen.

As far as I can tell, this happens since a few weeks to all rooms that ever had the setting to notify on every new message, which includes newly joined rooms, as that's the default. When that setting is later (since Synapse v0.21.0?) set to notify for mentions only, the badge count is still stepped up for new messages without a mention.

This does not happen for rooms that were "downgraded" to mentions only notifications earlier, possibly before Synapse v0.21.0.

Switching notifications off and on again doesn't help.

Seen on:
Synapse v0.21.0 (not sure if on earlier versions, too)
Riot Web v0.10.0-0.10.2 (and earlier versions?)
Riot Android 0.6.9 & 0.6.10

@zzottel
Copy link
Author

zzottel commented Jun 9, 2017

To clarify: I've seen this on a room that I recently joined, and on a room that I joined long ago and that was always set to notify for every message, but that I set to mentions only recently.

@turt2live
Copy link
Member

I've had this too. It seems to be fixed after synapse restarts.

Related (if not the same?): element-hq/element-web#3060

@zzottel
Copy link
Author

zzottel commented Jun 9, 2017

Can confirm it's fixed after a Synapse restart.

@zzottel
Copy link
Author

zzottel commented Jun 29, 2017

It seems this also leads to high battery usage on Riot Android as the badge update triggers a sync every time it is received.

@Mikaela
Copy link
Contributor

Mikaela commented Jun 29, 2017

It seems this also leads to high bettery usage on Riot Android as the badge update triggers a sync every time it is received.

element-hq/riot-android#1391

@richvdh
Copy link
Member

richvdh commented Jul 4, 2017

I'm also seeing this happening the other way around (ie, start with a room which is set to 'mentions only', switch it to 'all messages', and still only getting notifications for mentions). Again, a synapse restart fixes it.

It seems to be semi-reproducible by:

  • set room to mentions only
  • stop synapse
  • some events arrive
  • start synapse
  • more events arrive (no notifications yet, because still 'mentions only')
  • switch room to notify on 'all events'
  • yet more events arrive - still no notifications.

If that doesn't repro it, repeating the process a couple of times may do so

richvdh added a commit that referenced this issue Jul 4, 2017
Initialising `result` to `{}` in the parameters meant that every call to
_flatten_dict used the *same* target dictionary.

I'm hopeful this will fix #2270,
but I suspect it won't. (This code seems to have been here since forever,
unlike the bug, and I don't really think it explains the observed
behaviour). Still, it makes it hard to investigate the problem.
@richvdh
Copy link
Member

richvdh commented Jul 5, 2017

I've not been able to reproduce my version of this since landing #2332, so perhaps that has fixed it.

@turt2live: It doesn't sound the same as element-hq/element-web#3060, which reports a notification being shown in the favicon and titlebar but not the room list. AIUI @zzottel was seeing badges in the roomlist (when they weren't expected).

Anyway, I'm tentatively declaring this one fixed as of synapse develop.

@richvdh richvdh closed this as completed Jul 5, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants