element-meta icon indicating copy to clipboard operation
element-meta copied to clipboard

[Prep] EX: Stop receiving the app badge count pushes

Open manuroe opened this issue 6 months ago • 6 comments

Description

We want to compute the badge locally on iOS. It is also useful to stop having unread update pushes on Android because they are useless, could be considered as push spams and may be a reason why push gateway blocks some pushes (which means no notifications for the end user).

Acceptance criteria

  • The Sygnal adminstrator can configure the sending of unread and missed_call counts
  • The configuration is per app
  • EA and EI continue to get them
  • The app badge count on EXI is no more updated by the backend
  • EXA does not receive anymore unread or missed_call update pushes

Size estimate

S/M/L

Dependencies

  • None

Out of scope

Questions

  • [ ] Should we wait that EXI can compute the badge locally before enabling disable_badge_count?

Subtasks

Sygnal

  • [x] https://github.com/element-hq/sygnal/pull/421
  • [x] https://github.com/element-hq/sygnal/pull/423 - already has the optimization to avoid sending notifications if they only contained the badge for APN apps.
  • [x] https://github.com/element-hq/sygnal/pull/424 - adds the optimization to not send notifications if they only contained the badge for FCM apps.

SRE

  • [ ] Enable the new flag disable_badge_count on the sygnal instance used by EXA
  • [ ] Enable the new flag disable_badge_count on the sygnal instance used by EXI (It must be done after EXI can compute the badge locally)

manuroe avatar Oct 23 '25 14:10 manuroe

Added https://github.com/element-hq/sygnal/pull/423 to the list too.

jmartinesp avatar Oct 23 '25 15:10 jmartinesp

@jmartinesp @manuroe I assume you'll now want a new release of Sygnal, and to get that running on matrix.org infrastructure?

anoadragon453 avatar Oct 24 '25 12:10 anoadragon453

@jmartinesp @manuroe I assume you'll now want a new release of Sygnal, and to get that running on matrix.org infrastructure?

First we'd need to add the optimizations to avoid sending notification with badge only for Android (right now it would send a notification with just {'id': '', 'sender': ''}). I'm trying to come up with something that won't remove items with False values, and thinking if removing fields with empty strings makes sense or not.

Maybe I should to a more precise check, figure out if it's a badge only notification first and if it is, check if there are badges to be included.

jmartinesp avatar Oct 24 '25 13:10 jmartinesp

The optimization PR is https://github.com/element-hq/sygnal/pull/424.

jmartinesp avatar Oct 24 '25 14:10 jmartinesp

@jmartinesp @manuroe I assume you'll now want a new release of Sygnal, and to get that running on matrix.org infrastructure?

The implementation of this issue should now be done with https://github.com/element-hq/sygnal/pull/424 merged. We probably need that new version, and also to disable send_badge_counts for EXA in element.io either matrix.org? Could you confirm @manuroe ?

jmartinesp avatar Oct 27 '25 12:10 jmartinesp

Correct. Now we, the EX team, do not have any more to add to Sygnal, we are good for a release of it. For the moment, we want to disable badge counts only on EXA on matrix.org and element.io.

manuroe avatar Oct 27 '25 12:10 manuroe

A new Sygnal release has been created with the new changes: v0.17.0

The plan is to put the release out on matrix.org / vector.im tomorrow with send_badge_counts: false set for the EA and EXA pusher.

anoadragon453 avatar Nov 05 '25 16:11 anoadragon453

send_badge_counts has been set to false for Element Android Classic and Element X Android on matrix.org's sygnal instances. Please give it a try @jmartinesp @manuroe!

anoadragon453 avatar Nov 07 '25 11:11 anoadragon453

send_badge_counts has been set to false for Element Android Classic and Element X Android on matrix.org's sygnal instances. Please give it a try @jmartinesp @manuroe!

I believe this is working as expected: in notifications for events I see unread = null (so it couldn't be parsed because it's not there) and I don't receive push notifications for read receipt changes 🎉 .

jmartinesp avatar Nov 07 '25 11:11 jmartinesp