-
Notifications
You must be signed in to change notification settings - Fork 58
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
No notifications from open chat when Chrome is in background #1946
Comments
Actually we improved exactly these scenarios in the Talk 18 version. At least when switching to another tab that is. |
i also really need notifications to work when the browser tab is not active |
Likewise. For me on Desktop the notification is suspended until the Spreed tab is focused - defeating the purpose of the notification. |
See nextcloud/spreed#10544 :
Then you should see a request like Same request is sent when you:
Though in that case, you shouldn't receive any notifications from server (304 response status). Apart from it, we are not blocking any native pop-ups by code. |
|
Thanks for the confirmation, will try to reproduce it |
Yep, reproducible for me.
// in NotificationsApp
watch:{
notifications(value) {
console.log('watch notifications', value)
if (value[0]?.shouldNotify
&& this.showBrowserNotifications
&& this.webNotificationsThresholdId < value[0]?.notificationId) {
const n = new window.Notification(value[0]?.subject, {
title: value[0]?.subject,
lang: OC.getLocale(),
body: value[0]?.message,
icon: value[0]?.icon,
tag: value[0]?.notificationId,
})
}
},
}, Transferring this issue to nextcloud/notifications repo |
We are checking only active/inactive state. We can also check for frozen/ discarded states for suspended tabs. I'd say that a proper solution is to move notifications completely out from any DOM rendering, best to a worker to not be a part of the page that can be frozen. |
While yes, let's first do the quick fix of moving it to the root component |
For the reference:
In a frozen state, DOM is not updated, but background tasks are still running. In a discarded state, no new task from the task queue will be executed. So, to support discarded state or true push notifications, we would need to use workers what most of our libraries do not support. |
This particular issue seems to be fixed in the last update (29.0.3). |
Yes, we wanted to keep track it and look into web workers usage in the future for handling notifications. You may unsubscribe from receiving a notifications from this issue to not suddenly be bothered one day. Thanks again for the help with investigation! |
Hi I have issues generally in Nextcloud notifications. In both Desktop PWA and in browser. The notifications do not arrive and are not shown when the Windows is minimized (PWA and NC webpage). As soon as I open the Window, the notifications are shown (not always quickly, but at least they arrive). The notifications are in general too slow. Is it related to this issue and planned for 29.0.4, or is it not related? I am using 29.0.0 |
Then update please. Mostlikely it's fixed in 29.0.2 via #1948 |
Thanks a lot @nickvergessen! I confirm that it works now with 29.0.3. Nevertheless, the notification on the desktop (Web or PWA) is slow, it takes always about 20-30 seconds for the notification to arrive and get shown in Windows. Is there anything we can do for it? |
Yeah we do 30 second polling. So can be between 0 and 29 seconds. |
How to use GitHub
Steps to reproduce
Expected behaviour
Notifications should appear
Actual behaviour
Notifications appear after unminimizing the window, or not appear at all
Talk app
Talk app version: 19.0.0
Custom Signaling server configured: yes/no and version (see Talk administration settings:
/index.php/index.php/settings/admin/talk#signaling_server
)Custom TURN server configured: Yes
Custom STUN server configured: Yes
Browser
Microphone available: yes
Camera available: no
Operating system: Windows
Browser name: Chrome
Browser version: 123
The text was updated successfully, but these errors were encountered: