Repository navigation
feat(jellyfin): start polling fallback with the bot and add dashboard toggle - #139
kylepitcock wants to merge 3 commits into
Conversation
The poller existed but was never started. Start it from the bot's ready handler when JELLYFIN_POLLING_ENABLED=true, and record webhook-delivered items in the shared seen-items store so polling does not re-announce them. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Adds JELLYFIN_POLLING_ENABLED to the Jellyfin settings. Saving applies the change immediately by restarting the poller, and the poller is stopped before a bot restart so it does not keep a destroyed Discord client. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
4e6f15f to
3d0d939
Compare
|
Thanks for digging into this. The poller not being started isn't an oversight though: it was deliberately switched off in favour of webhooks a while ago, which is why the code is still there but unused. Before bringing it back I'd want to understand the empty-body issue with Jellyfin 12.1.0 better, since fixing webhook delivery would be preferable to running both. One technical concern if we do go this way: the webhook records episodes under the series TMDB ID ( Could you open an issue with the Jellyfin 12.1.0 webhook details (plugin version, logs) so we can look at the root cause first? |
Summary
jellyfinPoller.js) existed andapp.jsimported it, but nothing ever started it, soJELLYFIN_POLLING_ENABLEDhad no effect. The bot now starts it once it logs in.JELLYFIN_POLLING_ENABLED). Saving applies it immediately by restarting the poller, without a full bot restart.seen-itemsstore (deduplicator.checkAndRecord) so the poller doesn't announce an item the webhook already announced. This only records; it never skips a webhook, and test/batch notifications are ignored.Why
Webhook delivery can silently fail or arrive with an empty body (observed with Jellyfin 12.1.0, where the webhook plugin sent
content-length: 0). Polling reads from Jellyfin's API, so new items still get announced within the polling interval (5 minutes by default,JELLYFIN_POLLING_INTERVAL).Notes
seen-items(including those marked by the library seed) are not announced by polling.en.jsonand the template.node --check); not tested against a live Jellyfin server.🤖 Generated with Claude Code