Repository navigation
fix(scrobble): name an episode's series by a single ID - #9
Conversation
Floppy's scrobble endpoint looks a show up by its TVDB ID first, then IMDb, then TMDB, and takes a TMDB find() episode match as the show and episode played. TVDB numbers series and episodes separately, so a series ID can equal an unrelated episode's ID: Attack on Titan's TVDB series ID 267440 is also Strong Medicine S5E2. The plugin sent every series ID, so marking Attack on Titan episodes recorded Strong Medicine S5E2 instead, twelve episodes collapsing into one row. An episode scrobble now names its series by one ID: TMDB, which Floppy uses as the show directly, or else IMDb, then TVDB. Movies and episodes that only carry episode-level IDs are unchanged. Closes #6 Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
|
Warning Review limit reachedYou've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. Next included review available in 10 minutes. View limit detailsLimit details: You’ve used the included review currently available. Review configuration: ⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Advanced Run ID: 📒 Files selected for processing (2)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Code Review Completed! 🔥The code review was successfully completed based on your current configurations. Kody Guide: Usage and ConfigurationInteracting with Kody
Providing Context (Files & MCPs)Add these hints in your PR description (or a comment) to unlock deeper checks:
Current Kody ConfigurationReview OptionsThe following review options are enabled or disabled:
|
|
@coderabbitai review |
|
Problem
Closes #6
Related issue: N/A
Validation tasks: none
Watches that Silo sends to Floppy can land under a different show and episode. In the report, marking Attack on Titan S1E13–24 watched created a single Strong Medicine S5E2 row, and a Gold Rush scrobble created Burke's Law. Silo held the right IDs, and every request reported success.
For an episode, the plugin sends the series' TMDB, TVDB, and IMDb IDs. Floppy's scrobble handler looks the show up by the TVDB ID first, then the IMDb ID, through TMDB's find API, and falls back to the TMDB ID only after those lookups fail. When find returns an episode, Floppy records that episode's show, season, and episode number instead of the ones in the request. TVDB numbers series and episodes separately, so a series ID can equal an unrelated episode's ID. TheTVDB confirms this for all three shows in the report:
Floppy's current
latestbranch still resolves in this order.Approach
An episode scrobble now names its series by one ID: TMDB when Silo has it, which Floppy uses as the show directly; otherwise IMDb, where series and episode IDs never collide; otherwise TVDB. Floppy's progress and live-playback lookups already prefer the TMDB ID, so all three now resolve the same show. Movie scrobbles, and episodes that carry only episode-level IDs, are unchanged.
Validation
GOWORK=off go test -race ./...,go vet ./...,go build ./...,go run . manifest,gofmt -l ., andgolangci-lint run --new-from-rev=origin/mainpass.main, an episode whose series has TMDB, TVDB, and IMDb IDs sends all three; with this change it sends only the TMDB ID. It also covers the IMDb and TVDB fallbacks, a movie, and an episode with only episode-level IDs.main, with stock Floppy 26.8.27 and 26.9.24 containers. Plugin 0.3.0 from the catalog was compared with this branch and fix(history): import episode plays and every entry of a busy day #8, uploaded as a local build.Evidence: https://evidence.siloserver.org/r/silo-plugin-watchprovider-floppy/issue-6/
Risks
AI disclosure
🤖 Generated with Claude Code