Fribb / MyAnimeList.bundle

Plex Media Server Metadata Agent for MyAnimeList.net
147 stars 15 forks source link

Movie backgrounds populating, but show backgrounds are not. #30

Closed ilikpoptarts closed 2 years ago

ilikpoptarts commented 2 years ago

I have the TMDB setting enabled and API on. When matching a show using the agent, it will have several posters, no banners, and 1 background. When matching a movie, it will load several posters and several backgrounds. Since the movies are populating with several backgrounds... does that mean TMDB API is working? Or do movies populate with several backgrounds by default? I would think with the extra TMDB backgrounds, shows would include more than 1 background?

I've double checked correct API, checked plex console/logs for errors while getting metadata (no agent/API related errors), and checked that TMDB shows I'm parsing have background(backdrop) images. Both show and movies libraries are set to use myanimelist. Have checked that the shows/movies in question have matched from the mal agent. Have refreshed metadata after changes.

Fribb commented 2 years ago

Here is the list of images being requested:

Metadata MyAnimeList TheTVDB TheMovieDB
Posters X X X
Backgrounds X X
Banners X

As you can see in the Table, TheMovieDB does only provide Posters and Backgrounds but not Banners, this is only something that TheTVDB provides.

Since TheMovieDB only provides Backgrounds and Posters, if you have backgrounds added to the metadata the Agent would suggest that the metadata retrieval for TheMovieDB works.

I don't know which log file you looked into but in the plex\Library\Application Support\Plex Media Server\Logs\PMS Plugin Logs\net.fribbtastic.coding.plex.myanimelist.log there should be an INFO log output with Requesting Images for ID: XXXX with a status message Status: success.

There will also be DEBUG log output IF and only IF that requested Image is already present. You could look into the file and refresh metadata and see what the output is, it should mention that some Poster or Background from https://api.themoviedb.org "is already present"

ilikpoptarts commented 2 years ago

I was indeed looking at the wrong logs. Looking at the one you stated, I found that it was successfully mapping the shows to a mal ID, but that a TheMovieDB ID was not found. Looking at the full list of mappings, I found that although a TheMovieDB page does exist for the show... it did not have a mapping to the page in https://fribbtastic.net/mapping/anime-list-full.json . ("Mapping was available for mal_id=#### but ID for 'themoviedb' was not valid or did not exist") The movies that got backgrounds "correctly" I searched in the list and did have a mapping, which explains why my movies were getting backgrounds but my shows were not. Looking at the list just about every show does not have a mapping to TheMovieDB, but just about every movie does have a mapping. (for instance attack on titan = no TMDB ID, but attack on titan movie = has TMDB ID) I hope I am understanding this correctly and thank you for the quick and detailed response.

Fribb commented 2 years ago

Okay, now I understand what the problem is.

the mapping list is being generated using different projects as a baseline. Unfortunately, those projects don't offer a direct mapping between those services.

The Anime-Offline Database maps between MyAnimeList and Anidb. ScudLee anime-lists map between AniDb and TheTVDB for shows and TheMovieDB for Movies. But there is no or no reliable mapping between Anime Shows on TheMovieDB or Anime Movies on TheTVDB.

What my mapping generator does is to get the TheTVDB and/or IMDB ID and check that against the TheMovieDB API to get some sort of relation between those entries. TheMovieDB is fortunately and unfortunately the only way to do that because it offers the functionality for it to search for a different ID.

Basically, that means that there isn't a mapping on TheMovieDB that could have been used or found to make that connection between those IDs.