[Release] MyAnimeList.net Metadata Agent

I just checked what the real problem is and it is the nasty HTTP 429 Error: Too many Requests.

That is actually “normal” with that many users since MAL only really allows a single request every 15 seconds and since I already do that while creating the mapping this was bound to happen.

I really need to look into server-side caching on the VPS to prevent this. Though I doubt that I will prevent that completely.

Well something good happened. I just noticed in the last 24 hours all the missing art and metadata are now present for this seasons new series. Thanks!

Great, in the next two weeks I will have some time to test the new version of the Agent and if everything runs well I can release it.

Great news.

Question, I see you have a GitHub repo. Is that where you are working out of now?

Yes, I had the gihub repo for a while because someone suggested I add the Agent to the unofficial app store but this project is now disabled.

I will still have the releases on my own website but the code stays on github. I decided to do this to give people a choice, either they can support me and get a finished release from my website with a few ads (even though I’m not forcing you to disable your adblocker, it just would be nice) or they can clone or download the project from the github repo.

Man, what a ride this was, first my complete library gets destroyed, then I destroy it myself, then MAL going offline and disable a lot of functions.

With all that I’m proud to announce that the new version is ready. The MALAgent v6.0.0 is ready for you to use.

Like always see my Website here for more information and the download link.

If you find a bug please create an issue in the GitHub project page.

I also added an FAQ here

And now I need your help! This is important and every one of us is affected, some more than others.

I had to create a mapping between the MyAnimeList and theTVDB and TheMovieDB IDs to get the mapping between those websites to work. Unfortunately, I can’t go through almost 15000 entries and check if they are all correct.

So if you find any wrong pictures in your library please let me know. The project is also on GitHub here and you can create an issue here. With that, I can keep track of what has to change and where or you could just contribute to the project yourself. The more people help me do this the better the mapping will be.

With that being said, I hope you have fun with the new version.

PS: I will cancel my old server which currently still runs the old API which is not needed anymore so the older versions won’t work anymore in the near future.

Hey Fribbtastic, did you take over this project from Daraku? I have been using the MAL agent for a while now. I started to rely on the MAL agent mostly because half the shows I have are not present (or were not at the time) on theTVDB.

Am I understanding correctly that you changed it to use data from theTVDB and TheMovieDB? If that is the case, what does using your agent provide that the default one checking those sources wouldn’t do?

I have always been waiting hoping you would add personal MAL integration to track what episodes I have of a given show/ completion on my MAL connected back to my Plex completion tracking. At this point if meta data, posters and descriptions are not coming from MAL what DOES come from MAL?

Hey sweetaction. No, I have not taken over the Agent, I’m still the same guy I just changed my Nickname in the forums.

It is still the same Agent as well but with some major changes in how the metadata are requested and from where. You see, with the previous versions I used my own backend API to provide the information from the myanimelist website and TheTVDB. The API had and still has many issues because I never really viewed it as a permanent solution but as I wrote it there was not really any good alternative I could use.

The old API also only provided TheTVDB pictures and not from TheMovieDB which were interesting for Anime Movies but I didn’t know about theMovieDB at that time so I didn’t get the Idea.

However, with the new version of the Agent, I did some major changes. First, I decommissioned the Old API and while you will be able to use older versions of the Agent till 2019 there will be a time you won’t get any metadata anymore since the backend will be offline. Second, I moved to a different API, the atarashii API which provides a lot more functionality in a much cleaner way than I could ever hope to implement into the old API.

But this came with a compromise since this API was only providing data from myanimelist I had to figure out a way to get the theTVDB information back into the agent. I realised that with a mapping project that you can view on GitHub. This project contains lists of all available titles and a mapping file between the myanimelist ID and the ID on theTVDB or TheMovieDB.

Version 6 of the agent will request this mapping file, search for the title of the library entry on myanimelist and will get the results, the ID that is selected from the search results will then be used to get the detailed information of the anime like the synopsis etc. just like before but it will also look through the mapping file for the ID and, if available, will get a theTVDB ID or a TheMovieDB ID which the Agent will then use to request the additional banners, fan art (background) or posters for this Anime.

That way you will have both your Anime Series and Anime Movies filled with the information of off MyAnimeList and the pictures from TheTVDB or TheMovieDB.

For the last part of your request, I currently have to disappoint you. Don’t get me wrong this request is on my mind for a long time now and I actually had an angle of approach that I wanted to take but myanimelist “prevented me from doing so”.

What I mean by that is some time ago, right when I was finishing up the Agent, MyAnimeList went down. I still don’t really know what exactly happened but it made the whole website inaccessible. Many parts of the Website like the search, forums, communities etc were not active for weeks and sadly this is still the case for the official API.

And this is the important part. Since I use a 3rd party API to get the information from myanimelist it also provides the services to actually change what you have watched. However, this service relies on the official API of myanimelist and since this is not accessible there is no way to do this other than creating some program that goes over the website visually.

There is still no real information about what is going to happen to the official API since it is still out of order. Many 3rd party developers are frustrated and have even cancelled any support in regards to myanimelist until there is some concrete information and evidence that they are actively doing something and not just push the deadline further away.

My Approach to this was to create a Tautulli custom script which would get executed when tautulli recognised that a library entry is marked as watched. Then calls the atarashii API and updates the anime to the episode you watched.

So as you can see I have a plan but can’t really set it into motion because the most important part can’t be accessed and hopefully we will get some information on what is going to happen. If I have access to the new official API or they reactivate the old official API again then I can start this project and all you would have to do is install tautulli and set up the custom script and this would be it in theory.

You can also check the project page on my website which has, for example, the information which website provide what information.

Thanks for the quick response! Glad to know you are still around/ the same person.

I am updating to your latest version. For reference if you could update your insructions to include FREENAS plugin location for your agent. This is the location: /mnt/JailsVolume/Jails/plexmediaserver_1/var/db/plexdata/Plex Media Server/Plug-ins

  • where “JailsVolume” is the name of your Jail and “Jails” is the directory you placed your Jails in. plexmediaserver_1 is the name of the directory created by the FreeNAS plex plugin.

I added the

${JAIL_ROOT}/var/db/plexdata/Plex Media Server/

location to the install instructions as described here

Thanks again Fribbtastic. I do have one more question you might be able to help me with. Your instructions mention/ suggest using the absolute series scanner. I can’t seem to get that to work with your agent. if I use the plex default scanner it finds episodes and shows and works with your Agent but if I use the ASS option it doesn’t find anything. Do you have any idea’s what I might be missing?

“It doesn’t work” is always hard to answer because it can be a multitude of things starting from the Scanner is not being loaded to your media files, that they are not named properly so that the Scanner is not being able to recognize them or doesn’t know what to do with them.

I can’t say for sure what the reason for this is. My Library is that every Anime has their own folder in which the episodes are that have the following format

[title] - [absolute episode number] ([resolution]) [[Subgroup]].[type]

and it works flawlessly.

I would look through the logs and see if there are any hints on why you don’t get anything with the absolute scanner but if the default scanner is enough for you then I don’t see a reason why you should switch. As long as the scanner puts them into one season there is not really anything to worry about.

Problem is I just added a few large Anime that don’t get scanned correctly because there are so many episodes.

The only log I am finding is the Plex Media Scanner.log. It shows:

Oct 12, 2018 23:19:10.111 [0x809406800] INFO - Plex Media Scanner v1.12.2.4929-29f6d1796 - FreeBSD PC amd64 - build: freebsd-x86_64 - GMT -05:00
Oct 12, 2018 23:19:10.114 [0x809406800] ERROR - Failed to determine system locale: locale::facet::_S_create_c_locale name not valid. Defaulting to en-US.
Oct 12, 2018 23:19:10.114 [0x809406800] INFO - FreeBSD version: 11.0-RELEASE (FreeBSD 11.1-STABLE #0 r321665+9902d126c39(freenas/11.1-stable): Tue Aug 21 12:24:37 EDT 2018 root@nemesis.tn.ixsystems.com:/freenas-11-releng/freenas/_BE/objs/freenas-11-releng/freenas/_BE/os/sys/FreeNAS.amd64), language: en-US
Oct 12, 2018 23:19:10.114 [0x809406800] INFO - Processor Intel(R) Xeon(R) CPU E5-2620 v4 @ 2.10GHz
Oct 12, 2018 23:19:10.114 [0x809406800] INFO - /usr/pbi/plexmediaserver-amd64/share/plexmediaserver/Plex Media Scanner --scan --refresh --section 7
Oct 12, 2018 23:19:10.106 [0x809406400] WARN - Default locale is invalid; falling back on classic+UTF-8
Oct 12, 2018 23:19:10.118 [0x809406400] DEBUG - Opening 20 database sessions to library (com.plexapp.plugins.library), SQLite 3.13.0, threadsafe=1
Oct 12, 2018 23:19:10.253 [0x809406400] DEBUG - Scanning Anime Series - New Releases using en(Absolute Series Scanner) with 2308 current media items and 1 section locations in the database…
Oct 12, 2018 23:19:10.253 [0x8110b1c00] DEBUG - HTTP requesting GET http://127.0.0.1:32400/:/metadata/notify/cullTimeline?librarySectionID=7&sinceTime=1539403150
Oct 12, 2018 23:19:10.254 [0x809406400] DEBUG - Performing a scan with ‘Absolute Series Scanner’ (language: en virtual: 0).
Oct 12, 2018 23:19:10.254 [0x809406400] DEBUG - * Scanning /media/Anime New Releases
Oct 12, 2018 23:19:10.258 [0x809406400] ERROR - No module in VideoFiles
Oct 12, 2018 23:19:10.258 [0x809406400] ERROR - Error scanning directory .
Oct 12, 2018 23:19:10.259 [0x809406400] ERROR - No module in Absolute Series Scanner
Oct 12, 2018 23:19:10.259 [0x809406400] ERROR - We got an error scanning in /media/Anime New Releases
Oct 12, 2018 23:19:10.334 [0x809406400] DEBUG - Directory had 43 files, database had 42 files, can’t skip.
Oct 12, 2018 23:19:10.335 [0x809406400] ERROR - No module in Absolute Series Scanner
Oct 12, 2018 23:19:10.335 [0x809406400] ERROR - We got an error scanning in /media/Anime New Releases

I’m sorry but I don’t think I can help you with that. I don’t know how the scanner works or what could cause the errors.

You should ask the developer directly and see if they can help you fix the issue.

Hello,
I am not sure if anyone else is having the same problem, but recently every anime i add to my database does not reflect a result and i always get this message when i try to match the show using Myanimelist
" No matches found."

Is it because of the update? do i need to install anything new? or uninstall anything else?

Nouf.

You should update to the new Version. v6.0.0 is the most recent one and you can get it from here

If you already have the latest version then you should check how you named your anime files. The title needs to match the one on myanimelist or else the agent will not use them.

That solved it!
Thank you!!

Thanks for your help Fribbtastic. I have the logs posted in the ASS forum now.

Fribbtastic, I have rebuilt my server (because reasons) and everything seems to be working great. However I was wondering, do you have or are you going to have at any point an option to match seasons? Currently I have a delemna where I can either have each season it’s own listing or listed as individual seasons but without season descriptions in cases like Saki (season 01) https://myanimelist.net/anime/5671/Saki?q=saki
Saki The Nationals (Season 02)
https://myanimelist.net/anime/16123/Saki_Zenkoku-hen
Saki Episode of Side A (Season 03)
https://myanimelist.net/anime/10884/Saki_Achiga-hen__Episode_of_Side-A

How do you suggest handling something like this with your agent?

Currently there is no plan on realising this and I actually have no plan on doing this at all. I’m not saying that it isn’t possible but it would need a lot that happens behind the curtain for this to actually work for MyAnimeList.net.

MyAnimeList does not provide the information for this to be handled in any comfortable way and only provides that the individual Anime can have a sequel and/or prequel. Which means that the approach I would need to take to solve this would be to either maintain this on my own (with creating a mapping of IDs in their seasons = more work maintaining this) or do it through an algorithm in the Agent which will have its own problems of multiple requests etc.

And this would be the “easier” case because with Animes like One Piece or Naruto which are split into seasons more on the western market this would be almost impossibel unless there is a source that has the information of the relation between absolute and seasonal episode numbers. Unfortunately. the information are not provided by MyAnimeList.

The MyAnimeList Agent is purely to fill the listings in your library with Information from MyAnimeList and therefore the Library need to match how MyAnimeList provides the information. Of course, I have added a mapping file for TheTVDB and TheMovieDB but only for pictures but this is a file I also have to maintain and update periodically which consists currently of over 15k entries.

To “fix” your problem you have a few options.

  1. You keep to how MyAnimeList organizes Seasons as their own library listings and let the Agent do what it does
  2. Use Seasons in your library but without metadata for those other seasons
  3. Switching to another Metadata Agent

To the last point, TheTVDB does provide those seasons and IIRC HAMA also provides those information. If I’m not mistaken HAMA can also request MyAnimeList information but still uses the old API which will go down in a few months if it is not already. Though I would question the necessity to use MyAnimelist to provide the information if other websites like anidb is a lot better to do this.

But there might be something in the middle ground here. Collections. I have not used them before but I see them regularly browsing the usual reddit places for plex which could Organize your Library depending on related Library listings. Which would mean that while you still would need to have the usual own library listings for Saki Season 01/02/03 but they would be organized in the Saki Collection or something like that. Maybe that is a compromise which would be a good feature to have in the MyAnimeList agent.