Skip to content

Notification fallback counter#6181

Merged
bmarty merged 5 commits intodevelopfrom
feature/bma/notificationFallbackCounter
Feb 12, 2026
Merged

Notification fallback counter#6181
bmarty merged 5 commits intodevelopfrom
feature/bma/notificationFallbackCounter

Conversation

@bmarty
Copy link
Member

@bmarty bmarty commented Feb 11, 2026

Content

Change the message of the fallback notification from "You have new messages" to "You have X new messages", where X is a counter. The counter is incremented each time a new Push cannot be resolved to an event, and reset each time the user dismisses this notification.

Actually the counter is stored in the extras of the notification.

Motivation and context

Give more information about the potential new messages in the notification when the event cannot be decrypted.

Screenshots / GIFs

image

Tests

Let's exploit an issue that's not fixed on the SDK yet in order to test the feature. One can trigger the fallback notification by following these steps:

  • Enter airplane mode
  • From another account, send a message that should trigger a notification
  • Once the message is sent, redact it.
  • Exit airplane mode.
  • You should see the fallback notification with the counter.

If you send multiple messages then redact them while the mobile device is in airplane mode, you can see that the counter is updated.

When the fallback notification is dismissed, you can check that the next displayed fallback notification will have a reset counter.

Tested devices

  • Physical
  • Emulator
  • OS version(s):

Checklist

  • Changes have been tested on an Android device or Android emulator with API 24
  • UI change has been tested on both light and dark themes
  • Accessibility has been taken into account. See https://github.com/element-hq/element-x-android/blob/develop/CONTRIBUTING.md#accessibility
  • Pull request is based on the develop branch
  • Pull request title will be used in the release note, it clearly define what will change for the user
  • Pull request includes screenshots or videos if containing UI changes
  • You've made a self review of your PR

@bmarty bmarty requested a review from a team as a code owner February 11, 2026 15:54
@bmarty bmarty requested review from jmartinesp and removed request for a team February 11, 2026 15:54
@bmarty bmarty added the PR-Change For updates to an existing feature label Feb 11, 2026
@github-actions
Copy link
Contributor

github-actions bot commented Feb 11, 2026

📱 Scan the QR code below to install the build (arm64 only) for this PR.
QR code
If you can't scan the QR code you can install the build via this link: https://i.diawi.com/c4caJz

@codecov
Copy link

codecov bot commented Feb 11, 2026

Codecov Report

❌ Patch coverage is 84.44444% with 7 lines in your changes missing coverage. Please review.
✅ Project coverage is 81.40%. Comparing base (5cb5f5f) to head (3a86605).
⚠️ Report is 7 commits behind head on develop.

Files with missing lines Patch % Lines
...es/push/impl/notifications/NotificationRenderer.kt 20.00% 3 Missing and 1 partial ⚠️
...mpl/notifications/factories/NotificationCreator.kt 91.66% 1 Missing and 1 partial ⚠️
...push/impl/notifications/NotificationDataFactory.kt 92.30% 0 Missing and 1 partial ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #6181      +/-   ##
===========================================
+ Coverage    81.39%   81.40%   +0.01%     
===========================================
  Files         2570     2570              
  Lines        69761    69744      -17     
  Branches      8968     8964       -4     
===========================================
- Hits         56780    56774       -6     
+ Misses        9648     9642       -6     
+ Partials      3333     3328       -5     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Copy link
Member

@jmartinesp jmartinesp left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Works fine, thanks!

@sonarqubecloud
Copy link

@bmarty bmarty merged commit 346a24c into develop Feb 12, 2026
34 of 35 checks passed
@bmarty bmarty deleted the feature/bma/notificationFallbackCounter branch February 12, 2026 08:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

PR-Change For updates to an existing feature

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants