vosmiic / jellyfin-ani-sync

Synchronize anime watch status between Jellyfin and anime tracking sites.
GNU General Public License v3.0
215 stars 15 forks source link

Unable to work with anime where the sequel chain contains OVAs/Specials #96

Closed PythonCoderAS closed 6 months ago

PythonCoderAS commented 6 months ago

Describe the bug If the anime has any anime in the chain that isn't a full season in the sequel chain, such as Season 1 -> Season 2 -> Special -> Season 3, it will treat the Special as Season 3, and so on.

Logs

[2023-12-28 04:08:42.746 +00:00] [INF] [54] jellyfin_ani_sync.UpdateProviderStatus: Using provider Mal...
[2023-12-28 04:08:42.746 +00:00] [INF] [54] jellyfin_ani_sync.Api.MalApiCalls: Starting search for anime (GET https://api.myanimelist.net/v2/anime?q=Dr.STONE&fields=id%2Ctitle%2Calternative_titles%2Cnum_episodes%2Cstatus)...
[2023-12-28 04:08:42.747 +00:00] [INF] [54] Jellyfin.Plugin.PlaybackReporting.EventMonitorEntryPoint: Playback stop did not have a tracker : "D2057B15-CE53-5DE6-B0CA-7B59F16C3285-5c23ca7115144a1cbb3e9bc748b54a40-5a9485c2f6ce85037721267c17dbc343"
[2023-12-28 04:08:43.892 +00:00] [ERR] [3] Jellyfin.Server.Middleware.ExceptionMiddleware: Error processing request: "Unexpected end of request content". URL "POST" "/Sessions/Playing/Progress".
[2023-12-28 04:08:43.947 +00:00] [INF] [3] jellyfin_ani_sync.Api.MalApiCalls: Search complete
[2023-12-28 04:08:43.948 +00:00] [INF] [3] jellyfin_ani_sync.UpdateProviderStatus: (Mal) Found matching series: Dr. Stone
[2023-12-28 04:08:43.948 +00:00] [INF] [3] jellyfin_ani_sync.UpdateProviderStatus: (Mal) Attempting to get season 1...
[2023-12-28 04:08:43.948 +00:00] [INF] [3] jellyfin_ani_sync.Api.MalApiCalls: Retrieving an anime from MAL (GET https://api.myanimelist.net/v2/anime/38691?fields=title%2Crelated_anime%2Cmy_list_status%2Cnum_episodes)...
[2023-12-28 04:08:44.225 +00:00] [INF] [66] jellyfin_ani_sync.Api.MalApiCalls: Anime retrieval complete
[2023-12-28 04:08:44.227 +00:00] [INF] [66] jellyfin_ani_sync.UpdateProviderStatus: (Mal) Attempting to get season 2...
[2023-12-28 04:08:44.227 +00:00] [INF] [66] jellyfin_ani_sync.Api.MalApiCalls: Retrieving an anime from MAL (GET https://api.myanimelist.net/v2/anime/40852?fields=title%2Crelated_anime%2Cmy_list_status%2Cnum_episodes)...
[2023-12-28 04:08:44.517 +00:00] [INF] [66] jellyfin_ani_sync.Api.MalApiCalls: Anime retrieval complete
[2023-12-28 04:08:44.518 +00:00] [INF] [66] jellyfin_ani_sync.UpdateProviderStatus: (Mal) Attempting to get season 3...
[2023-12-28 04:08:44.518 +00:00] [INF] [66] jellyfin_ani_sync.Api.MalApiCalls: Retrieving an anime from MAL (GET https://api.myanimelist.net/v2/anime/50612?fields=title%2Crelated_anime%2Cmy_list_status%2Cnum_episodes)...
[2023-12-28 04:08:44.790 +00:00] [INF] [66] jellyfin_ani_sync.Api.MalApiCalls: Anime retrieval complete
[2023-12-28 04:08:44.790 +00:00] [INF] [66] jellyfin_ani_sync.UpdateProviderStatus: (Mal) Season being watched is Dr. Stone: Ryuusui
[2023-12-28 04:08:44.790 +00:00] [INF] [66] jellyfin_ani_sync.Api.MalApiCalls: Retrieving an anime from MAL (GET https://api.myanimelist.net/v2/anime/50612?fields=title%2Crelated_anime%2Cmy_list_status%2Cnum_episodes)...
[2023-12-28 04:08:44.990 +00:00] [INF] [61] jellyfin_ani_sync.Api.MalApiCalls: Anime retrieval complete
[2023-12-28 04:08:44.990 +00:00] [INF] [61] jellyfin_ani_sync.UpdateProviderStatus: User does not have plan to watch only ticked
[2023-12-28 04:08:44.990 +00:00] [INF] [61] jellyfin_ani_sync.UpdateProviderStatus: (Mal) Series (Dr. Stone: Ryuusui) found on Completed list, but user does not want to automatically set as rewatching. Skipping
[2023-12-28 04:08:44.990 +00:00] [INF] [61] jellyfin_ani_sync.UpdateProviderStatus: (Mal) Series (Dr. Stone: Ryuusui) found on Completed list
[2023-12-28 04:08:44.990 +00:00] [INF] [61] jellyfin_ani_sync.UpdateProviderStatus: (Mal) Series (Dr. Stone: Ryuusui) found on Completed list, but user does not want to automatically set as rewatching. Skipping

To Reproduce Steps to reproduce the behavior:

  1. Add a show on Jellyfin with a special before a season
  2. Watch episode in season
  3. See error

Expected behavior The plugin should know that the special is not part of the season.

Screenshots N/A

Desktop (please complete the following information):

Additional context Issue on Anime-Lists/anime-lists: https://github.com/Anime-Lists/anime-lists/issues/414#issuecomment-1870597526

vosmiic commented 6 months ago

This is not an issue on the anime list side, as its falling back to manually searching the API. If it is an issue its on MAL's side as the special is categorised as the sequel. Not much we can do.

PythonCoderAS commented 5 months ago

This is not an issue on the anime list side, as its falling back to manually searching the API. If it is an issue its on MAL's side as the special is categorised as the sequel. Not much we can do.

This is intentional because the special is critical to the story and is necessary for the third season to make sense. That anime isn't the only anime with something between seasons, because I can think of the Demon Slayer movie for example

vosmiic commented 5 months ago

I'll check if we can add a flag to not retrieve specials when searching. It is strange that the plugin is falling back to manually searching the API though, this is the old and unreliable method of identifying shows. Normally it is able to identify shows using the anime list XML file, for more reliable detection make sure you are using one of the recommended metadata providers.

PythonCoderAS commented 5 months ago

I'll check if we can add a flag to not retrieve specials when searching. It is strange that the plugin is falling back to manually searching the API though, this is the old and unreliable method of identifying shows. Normally it is able to identify shows using the anime list XML file, for more reliable detection make sure you are using one of the recommended metadata providers.

I am using the Anilist provider primarily, should I switch to TVDB? I didn't bother mostly because I'm using Sonarr which is already using TVDB.

vosmiic commented 5 months ago

I am using the Anilist provider primarily, should I switch to TVDB? I didn't bother mostly because I'm using Sonarr which is already using TVDB.

If you can yeah the TVDB metadata provider works a lot better with the plugin as we can map directly to results in the anime list XML file we use.