Coach page can produce duplicative polling for notifications
❌ This issue is not open for contribution. Visit Contributing guidelines to learn about the contributing process and how to find suitable issues.
Observed behavior
When a Coach is assigned to multiple Classes, their repeated navigation from the class list page into a class causes duplicative polling for Coach notifications.
Errors and logs
The following logs occurred from opening multiple classes multiple times from the class list page, resulting in more polling requests than there were classes. Observe 7 requests all within 1 second.
INFO 2026-01-07 11:59:07,007 127.0.0.1 - - "GET /coach/api/notifications/" 200 0 "http://localhost:8080/en/coach/" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/143.0.0.0 Safari/537.36"
INFO 2026-01-07 11:59:07,226 127.0.0.1 - - "GET /coach/api/notifications/" 200 0 "http://localhost:8080/en/coach/" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/143.0.0.0 Safari/537.36"
INFO 2026-01-07 11:59:07,288 127.0.0.1 - - "GET /coach/api/notifications/" 200 0 "http://localhost:8080/en/coach/" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/143.0.0.0 Safari/537.36"
INFO 2026-01-07 11:59:07,564 127.0.0.1 - - "GET /coach/api/notifications/" 200 0 "http://localhost:8080/en/coach/" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/143.0.0.0 Safari/537.36"
INFO 2026-01-07 11:59:07,788 127.0.0.1 - - "GET /coach/api/notifications/" 200 0 "http://localhost:8080/en/coach/" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/143.0.0.0 Safari/537.36"
INFO 2026-01-07 11:59:07,817 127.0.0.1 - - "GET /coach/api/notifications/" 200 0 "http://localhost:8080/en/coach/" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/143.0.0.0 Safari/537.36"
INFO 2026-01-07 11:59:07,914 127.0.0.1 - - "GET /coach/api/notifications/" 200 0 "http://localhost:8080/en/coach/" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/143.0.0.0 Safari/537.36"
Expected behavior
The Coach SPA should avoid duplicative polling for notifications, and register one polling utility when the page is loaded.
User-facing consequences
If the Coach is assigned to several classes, and navigates to and from those classes without refreshing the page, the browser could generate significant load on the Kolibri server through repeated requests. This could be compounded by multiple Coaches working on their individual Classes from separate devices.
Steps to reproduce
For example, a Coach is assigned to 3 classes shown in the screenshot below (cont'd below)
if the Coach takes the following navigation steps from that page, the frontend will start 3 pollers for notifications:
- Opens 'All Class'
- Goes back via 'All classes' link
- Opens 'A Class'
- Goes back via 'All classes' link
- Opens 'B Class'
- Goes back via 'All classes' link
Context
Kolibri develop branch, as of 0.19
Ubuntu
Chrome
From @rtibbles:
I think it gets started in vuex, so there's no great place to put the cleanup hook (is probably why this happened)
Hi, I'd like to work on this issue
Hi! 👋
Thanks so much for your interest! This issue is not open for contribution. Visit Contributing guidelines to learn about the contributing process and how to find suitable issues. If there are no unassigned 'help wanted' issues available, please wait until new ones are added.
We really appreciate your willingness to help. 😊
Are you preparing for Google Summer of Code? See our GSoC guidelines.