Skip to content

Conversation

@mahibi
Copy link
Collaborator

@mahibi mahibi commented Nov 20, 2025

When push notification was received but NC server was not available, no notification was shown (Should be an edge case but might fix 'some' missing notifications).

If fetching of notification info from NC server fails, the decrypted subject from the push notification itself is used. In this case less features are available (no avatar, no inline reply, no "mark as read").

fetch of Nextcloud notification infos successful fetch of Nextcloud notification infos failed
grafik grafik

For testing, e.g. just replace the url in getUrlForNcNotificationWithId method.

Should be further improved in followup PRs by:

  • migrate API call to coroutine
  • add retry and (exponential) timeout handling

🏁 Checklist

  • ⛑️ Tests (unit and/or integration) are included or not needed
  • 🔖 Capability is checked or not needed
  • 🔙 Backport requests are created or not needed: /backport to stable-xx.x
  • 📅 Milestone is set
  • 🌸 PR title is meaningful (if it should be in the changelog: is it meaningful to users?)

when notificationUser is not known (because get NC notification failed), do
not style notification with avatar
not show mark as read
not show reply action
... these things will need infos from NC notification!

Signed-off-by: Marcel Hibbe <[email protected]>
... the ugly "fallback" icons should not be shown in this case

Signed-off-by: Marcel Hibbe <[email protected]>
Signed-off-by: Marcel Hibbe <[email protected]>
@mahibi mahibi force-pushed the bugfix/noid/improveNotificationHandling branch from c268721 to 78383fa Compare November 24, 2025 11:22
@github-actions
Copy link
Contributor

Codacy

Lint

TypemasterPR
Warnings9999
Errors00

SpotBugs

CategoryBaseNew
Bad practice66
Correctness1010
Dodgy code5454
Internationalization33
Malicious code vulnerability33
Performance44
Security11
Total8181

@github-actions
Copy link
Contributor

APK file: https://www.kaminsky.me/nc-dev/android-artifacts/5565.apk

qrcode

To test this change/fix you can simply download above APK file and install and test it in parallel to your existing Nextcloud app.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants