Skip to content

enh(updatenotification): Try to make legacy-notification smart(er)#43742

Draft
joshtrichards wants to merge 1 commit intomasterfrom
fix/updatenotification-legacy-toast
Draft

enh(updatenotification): Try to make legacy-notification smart(er)#43742
joshtrichards wants to merge 1 commit intomasterfrom
fix/updatenotification-legacy-toast

Conversation

@joshtrichards
Copy link
Copy Markdown
Member

Summary

If updatenotification app is enabled (the default), but the notifications (push notifications) app is disabled, we load a so-called legacy-notification as a toast message as a fallback to inform admins about new available updates. If there is a new version of Server available, a new toast is generated upon every DOM reload. An admin (effectively) can't dismiss it:

image

If a user that disables push notifications still wishes to periodically be notified in the Web UI about new updates they must tolerate the constant toasts all day long every day without the ability to dismiss them beyond the next page load.

Example: Joe User is happily running Server v27, but doesn't plan to update to v28 soon. They don't want to be told about the latest v28 release all day long every day long in a new toast.

Alternatives from the user's perspective:

  • Re-enable the notifications app even if they won't really want to
  • Don't use an account with admin privileges for everyday work
  • Decide it's not worth it and disable all update notifications (by either disabling the updatenotification app outright or setting updatechecker: false in config.php) [likely not an action we want to encourage if it's merely out of frustration with the constant toasts]

This PR tries to make this legacy code a tiny bit smart, by only sending the notification one day a week and on the half hour only.

Currently it's set to every 7th day, but maybe every 4th or something makes more sense (in order to be less likely to skip a weekday/etc.).

Keep in mind this doesn't have to be perfect. It's already only a fallback that is only utilized when the notifications app is disabled.

TODO

  • Confirm hard coded every X day makes sense

Checklist

Fixes #43645 

Signed-off-by: Josh <josh.t.richards@gmail.com>
@joshtrichards joshtrichards marked this pull request as draft February 22, 2024 23:10
@susnux susnux added this to the Nextcloud 30 milestone Apr 18, 2024
@skjnldsv skjnldsv modified the milestones: Nextcloud 30, Nextcloud 31 Aug 6, 2024
@blizzz blizzz modified the milestones: Nextcloud 31, Nextcloud 32 Jan 29, 2025
@skjnldsv skjnldsv modified the milestones: Nextcloud 32, Nextcloud 33 Sep 28, 2025
@blizzz blizzz modified the milestones: Nextcloud 33, Nextcloud 34 Feb 16, 2026
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.

Fix or retire legacy notifications in the Updater to avoid constant updater notifications if the Notifications app is disabled

4 participants