[Rel] HTTP Anidb Metadata Agent (HAMA)

Not sure if this has been fixed already but I keep getting an error when hama tries to download the anime titles from http://anidb.net/api/anime-titles.xml.gz. AniDB wants a cookie when you download it so a wget will only work if you add something like -b key=val to it.

Edit: Just checked their wiki and they have a limit on only downloading it once per day.

how do you get MyAnimeList to be you ā€œgenreā€ finder ive been trying for a while now

Hi, I’m having trouble with matching a few series.
One of the cases is Bannou Bunka Nekomusume (1998), for some reason it doesn’t find a match using HAMA, even pointing out to the anidb entry using ANIDB1 mode

This is what the log file shows

2019-12-16 18:46:19,033 (1e94) :  INFO (agentkit:957) - Searching for matches for {'show': 'Bannou Bunka Nekomusume (1998)', 'id': '2437682', 'year': '1998'}
2019-12-16 18:46:19,035 (1e94) :  DEBUG (networking:143) - Requesting 'http://127.0.0.1:32400/library/metadata/2437682/tree'
2019-12-16 18:46:19,048 (1e94) :  INFO (common:151) - ==== common.PlexLog(file="E:\Users\Toto Saurio\AppData\Local\Plex Media Server\Plug-in Support\Data\com.plexapp.agents.hama\DataItems\_Logs\Anime\Bannou Bunka Nekomusume (1998).agent-search.log")
2019-12-16 18:46:19,089 (1e94) :  DEBUG (networking:138) - Fetching 'http://thetvdb.com/api/GetSeries.php?seriesname=Bannou%20Bunka%20Nekomusume%20(1998)' from the HTTP cache
2019-12-16 18:46:19,128 (1e94) :  DEBUG (runtime:88) - Sending packed state data (104 bytes)
2019-12-16 18:46:19,128 (1e94) :  DEBUG (runtime:924) - Response: [200] str, 320 bytes
2019-12-16 18:49:26,664 (ab0) :  DEBUG (runtime:717) - Handling request GET /:/plugins/com.plexapp.agents.hama/messaging/function/X0FnZW50S2l0OlNlYXJjaA__/Y2VyZWFsMQoxCmxpc3QKMApyMAo_/Y2VyZWFsMQoyCmRpY3QKZGljdAo2CnMyCmVuczQKbGFuZ2IwczYKbWFudWFsYjFzNwpwcmltYXJ5aTAKczcKdmVyc2lvbnIxCnM2Cmt3YXJnc3M3ClRWX1Nob3dzMTAKbWVkaWFfdHlwZTExCnMxNgozZTIwNDI3ZTBjZTFiYWMyczE3Cm9wZW5TdWJ0aXRsZXNIYXNoczEKMXM3CmVwaXNvZGVzMwoxMENzNApuYW1lczEKMXM4CmVwaXNvZGljczMwCkJhbm5vdSBCdW5rYSBOZWtvbXVzdW1lICgxOTk4KXM0CnNob3dzNAoxOTk4czYKc2Vhc29ubnM0CnllYXJzMTU3CkYlM0ElNUNBbmltZSU1Q0Jhbm5vdSUyMEJ1bmthJTIwTmVrb211c3VtZSUyMCgxOTk4KSUyMFthbmRpYi01MjZdJTVDW0V4aWxlZC1EZXN0aW55XSUyMEJhbm5vdSUyMEJ1bmthJTIwTmVrb211c3VtZSUyMCgxOTk4KSUyMC0lMjAxMCVDMyVBNyUyMCgxNDk5NTdFMyklMkVta3ZzOApmaWxlbmFtZXM0MAo5MWNmNDlhZjBlMTY5YTZjYzhmMDMxZjYwOWJiMGExYTEzMjM2NDc1czgKcGxleEhhc2hzNwoxNDA2MTU2czgKZHVyYXRpb25zNwoyNDM3NjgyczIKaWRyMAo_
2019-12-16 18:49:26,665 (ab0) :  DEBUG (runtime:49) - Received packed state data (80 bytes)
2019-12-16 18:49:26,665 (ab0) :  DEBUG (runtime:814) - Found route matching /:/plugins/com.plexapp.agents.hama/messaging/function/X0FnZW50S2l0OlNlYXJjaA__/Y2VyZWFsMQoxCmxpc3QKMApyMAo_/Y2VyZWFsMQoyCmRpY3QKZGljdAo2CnMyCmVuczQKbGFuZ2IwczYKbWFudWFsYjFzNwpwcmltYXJ5aTAKczcKdmVyc2lvbnIxCnM2Cmt3YXJnc3M3ClRWX1Nob3dzMTAKbWVkaWFfdHlwZTExCnMxNgozZTIwNDI3ZTBjZTFiYWMyczE3Cm9wZW5TdWJ0aXRsZXNIYXNoczEKMXM3CmVwaXNvZGVzMwoxMENzNApuYW1lczEKMXM4CmVwaXNvZGljczMwCkJhbm5vdSBCdW5rYSBOZWtvbXVzdW1lICgxOTk4KXM0CnNob3dzNAoxOTk4czYKc2Vhc29ubnM0CnllYXJzMTU3CkYlM0ElNUNBbmltZSU1Q0Jhbm5vdSUyMEJ1bmthJTIwTmVrb211c3VtZSUyMCgxOTk4KSUyMFthbmRpYi01MjZdJTVDW0V4aWxlZC1EZXN0aW55XSUyMEJhbm5vdSUyMEJ1bmthJTIwTmVrb211c3VtZSUyMCgxOTk4KSUyMC0lMjAxMCVDMyVBNyUyMCgxNDk5NTdFMyklMkVta3ZzOApmaWxlbmFtZXM0MAo5MWNmNDlhZjBlMTY5YTZjYzhmMDMxZjYwOWJiMGExYTEzMjM2NDc1czgKcGxleEhhc2hzNwoxNDA2MTU2czgKZHVyYXRpb25zNwoyNDM3NjgyczIKaWRyMAo_
2019-12-16 18:49:26,667 (ab0) :  INFO (agentkit:957) - Searching for matches for {'openSubtitlesHash': '3e20427e0ce1bac2', 'episode': '1', 'name': '10C', 'episodic': '1', 'show': 'Bannou Bunka Nekomusume (1998)', 'season': '1998', 'plexHash': '91cf49af0e169a6cc8f031f609bb0a1a13236475', 'filename': 'F%3A%5CAnime%5CBannou%20Bunka%20Nekomusume%20(1998)%20[andib-526]%5C[Exiled-Destiny]%20Bannou%20Bunka%20Nekomusume%20(1998)%20-%2010%C3%A7%20(149957E3)%2Emkv', 'year': None, 'duration': '1406156', 'id': '2437682'}
2019-12-16 18:49:26,667 (ab0) :  DEBUG (networking:143) - Requesting 'http://127.0.0.1:32400/library/metadata/2437682/tree'
2019-12-16 18:49:26,677 (ab0) :  INFO (common:151) - ==== common.PlexLog(file="E:\Users\Toto Saurio\AppData\Local\Plex Media Server\Plug-in Support\Data\com.plexapp.agents.hama\DataItems\_Logs\Anime\Bannou Bunka Nekomusume (1998) [andib-526].agent-search.log")
2019-12-16 18:49:26,717 (ab0) :  DEBUG (networking:138) - Fetching 'http://thetvdb.com/api/GetSeries.php?seriesname=Bannou%20Bunka%20Nekomusume%20(1998)' from the HTTP cache
2019-12-16 18:49:26,766 (ab0) :  DEBUG (runtime:88) - Sending packed state data (104 bytes)
2019-12-16 18:49:26,766 (ab0) :  DEBUG (runtime:924) - Response: [200] str, 320 bytes
2019-12-16 18:49:26,818 (468) :  DEBUG (runtime:717) - Handling request GET /:/plugins/com.plexapp.agents.hama/messaging/function/X0FnZW50S2l0OlVwZGF0ZU1ldGFkYXRh/Y2VyZWFsMQoxCmxpc3QKMApyMAo_/Y2VyZWFsMQoxCmRpY3QKMTAKczIKZW5zNApsYW5nYjFzNQpmb3JjZWIwczgKcGVyaW9kaWNzNwoyNDM3NjQ3czQKZGJpZGkwCnM3CnZlcnNpb25uczEwCnBhcmVudEdVSURuczgKcGFyZW50SURzNwpUVl9TaG93czEwCm1lZGlhX3R5cGVzNDUKY29tLnBsZXhhcHAuYWdlbnRzLmhhbWE6Ly9hbmlkYi1hMzYyMj9sYW5nPWVuczQKZ3VpZHMxMQphbmlkYi1hMzYyMnMyCmlkcjAK
2019-12-16 18:49:26,819 (468) :  DEBUG (runtime:49) - Received packed state data (80 bytes)
2019-12-16 18:49:26,819 (468) :  DEBUG (runtime:814) - Found route matching /:/plugins/com.plexapp.agents.hama/messaging/function/X0FnZW50S2l0OlVwZGF0ZU1ldGFkYXRh/Y2VyZWFsMQoxCmxpc3QKMApyMAo_/Y2VyZWFsMQoxCmRpY3QKMTAKczIKZW5zNApsYW5nYjFzNQpmb3JjZWIwczgKcGVyaW9kaWNzNwoyNDM3NjQ3czQKZGJpZGkwCnM3CnZlcnNpb25uczEwCnBhcmVudEdVSURuczgKcGFyZW50SURzNwpUVl9TaG93czEwCm1lZGlhX3R5cGVzNDUKY29tLnBsZXhhcHAuYWdlbnRzLmhhbWE6Ly9hbmlkYi1hMzYyMj9sYW5nPWVuczQKZ3VpZHMxMQphbmlkYi1hMzYyMnMyCmlkcjAK
2019-12-16 18:49:26,821 (468) :  DEBUG (model:32) - Loading model with GUID com.plexapp.agents.hama://anidb-a3622?lang=en
2019-12-16 18:49:26,822 (468) :  DEBUG (model:234) - Deserializing from E:\Users\Toto Saurio\AppData\Local\Plex Media Server\Metadata\TV Shows\6\55e8c21f32575f55a9029ab73279ff18b463d27.bundle\Contents\com.plexapp.agents.hama\Info.xml
2019-12-16 18:49:26,825 (468) :  DEBUG (networking:143) - Requesting 'http://127.0.0.1:32400/library/metadata/2437647/tree'
2019-12-16 18:49:26,834 (468) :  INFO (common:151) - ==== common.PlexLog(file="E:\Users\Toto Saurio\AppData\Local\Plex Media Server\Plug-in Support\Data\com.plexapp.agents.hama\DataItems\_Logs\Anime\Love Position, Legend of the Halley.agent-update.log")
2019-12-16 18:49:27,007 (468) :  DEBUG (model:229) - Serializing to E:\Users\Toto Saurio\AppData\Local\Plex Media Server\Metadata\TV Shows\6\55e8c21f32575f55a9029ab73279ff18b463d27.bundle\Contents\com.plexapp.agents.hama\Info.xml
2019-12-16 18:49:27,010 (468) :  DEBUG (runtime:88) - Sending packed state data (104 bytes)
2019-12-16 18:49:27,010 (468) :  DEBUG (runtime:924) - Response: [200] str, 16 bytes
2019-12-16 18:49:32,239 (30b4) :  DEBUG (runtime:717) - Handling request GET /:/plugins/com.plexapp.agents.hama/messaging/function/X0FnZW50S2l0OlNlYXJjaA__/Y2VyZWFsMQoxCmxpc3QKMApyMAo_/Y2VyZWFsMQoyCmRpY3QKZGljdAo2CnMyCmVuczQKbGFuZ2IxczYKbWFudWFsYjFzNwpwcmltYXJ5aTAKczcKdmVyc2lvbnIxCnM2Cmt3YXJnc3M3ClRWX1Nob3dzMTAKbWVkaWFfdHlwZTExCnMxNgozZTIwNDI3ZTBjZTFiYWMyczE3Cm9wZW5TdWJ0aXRsZXNIYXNoczEKMXM3CmVwaXNvZGVzMwoxMENzNApuYW1lczEKMXM4CmVwaXNvZGljczMwCkJhbm5vdSBCdW5rYSBOZWtvbXVzdW1lICgxOTk4KXM0CnNob3dzNAoxOTk4czYKc2Vhc29ubnM0CnllYXJzMTU3CkYlM0ElNUNBbmltZSU1Q0Jhbm5vdSUyMEJ1bmthJTIwTmVrb211c3VtZSUyMCgxOTk4KSUyMFthbmRpYi01MjZdJTVDW0V4aWxlZC1EZXN0aW55XSUyMEJhbm5vdSUyMEJ1bmthJTIwTmVrb211c3VtZSUyMCgxOTk4KSUyMC0lMjAxMCVDMyVBNyUyMCgxNDk5NTdFMyklMkVta3ZzOApmaWxlbmFtZXM0MAo5MWNmNDlhZjBlMTY5YTZjYzhmMDMxZjYwOWJiMGExYTEzMjM2NDc1czgKcGxleEhhc2hzNwoxNDA2MTU2czgKZHVyYXRpb25zNwoyNDM3NjgyczIKaWRyMAo_
2019-12-16 18:49:32,240 (30b4) :  DEBUG (runtime:49) - Received packed state data (80 bytes)
2019-12-16 18:49:32,240 (30b4) :  DEBUG (runtime:814) - Found route matching /:/plugins/com.plexapp.agents.hama/messaging/function/X0FnZW50S2l0OlNlYXJjaA__/Y2VyZWFsMQoxCmxpc3QKMApyMAo_/Y2VyZWFsMQoyCmRpY3QKZGljdAo2CnMyCmVuczQKbGFuZ2IxczYKbWFudWFsYjFzNwpwcmltYXJ5aTAKczcKdmVyc2lvbnIxCnM2Cmt3YXJnc3M3ClRWX1Nob3dzMTAKbWVkaWFfdHlwZTExCnMxNgozZTIwNDI3ZTBjZTFiYWMyczE3Cm9wZW5TdWJ0aXRsZXNIYXNoczEKMXM3CmVwaXNvZGVzMwoxMENzNApuYW1lczEKMXM4CmVwaXNvZGljczMwCkJhbm5vdSBCdW5rYSBOZWtvbXVzdW1lICgxOTk4KXM0CnNob3dzNAoxOTk4czYKc2Vhc29ubnM0CnllYXJzMTU3CkYlM0ElNUNBbmltZSU1Q0Jhbm5vdSUyMEJ1bmthJTIwTmVrb211c3VtZSUyMCgxOTk4KSUyMFthbmRpYi01MjZdJTVDW0V4aWxlZC1EZXN0aW55XSUyMEJhbm5vdSUyMEJ1bmthJTIwTmVrb211c3VtZSUyMCgxOTk4KSUyMC0lMjAxMCVDMyVBNyUyMCgxNDk5NTdFMyklMkVta3ZzOApmaWxlbmFtZXM0MAo5MWNmNDlhZjBlMTY5YTZjYzhmMDMxZjYwOWJiMGExYTEzMjM2NDc1czgKcGxleEhhc2hzNwoxNDA2MTU2czgKZHVyYXRpb25zNwoyNDM3NjgyczIKaWRyMAo_
2019-12-16 18:49:32,240 (30b4) :  INFO (agentkit:957) - Searching for matches for {'openSubtitlesHash': '3e20427e0ce1bac2', 'episode': '1', 'name': '10C', 'episodic': '1', 'show': 'Bannou Bunka Nekomusume (1998)', 'season': '1998', 'plexHash': '91cf49af0e169a6cc8f031f609bb0a1a13236475', 'filename': 'F%3A%5CAnime%5CBannou%20Bunka%20Nekomusume%20(1998)%20[andib-526]%5C[Exiled-Destiny]%20Bannou%20Bunka%20Nekomusume%20(1998)%20-%2010%C3%A7%20(149957E3)%2Emkv', 'year': None, 'duration': '1406156', 'id': '2437682'}
2019-12-16 18:49:32,240 (30b4) :  DEBUG (networking:143) - Requesting 'http://127.0.0.1:32400/library/metadata/2437682/tree'
2019-12-16 18:49:32,253 (30b4) :  INFO (common:151) - ==== common.PlexLog(file="E:\Users\Toto Saurio\AppData\Local\Plex Media Server\Plug-in Support\Data\com.plexapp.agents.hama\DataItems\_Logs\Anime\Bannou Bunka Nekomusume (1998) [andib-526].agent-search.log")
2019-12-16 18:49:32,296 (30b4) :  DEBUG (networking:138) - Fetching 'http://thetvdb.com/api/GetSeries.php?seriesname=Bannou%20Bunka%20Nekomusume%20(1998)' from the HTTP cache
2019-12-16 18:49:32,336 (30b4) :  DEBUG (runtime:88) - Sending packed state data (104 bytes)
2019-12-16 18:49:32,336 (30b4) :  DEBUG (runtime:924) - Response: [200] str, 320 bytes
2019-12-16 18:49:36,334 (3138) :  DEBUG (runtime:717) - Handling request GET /:/plugins/com.plexapp.agents.hama/messaging/function/X0FnZW50S2l0OlNlYXJjaA__/Y2VyZWFsMQoxCmxpc3QKMApyMAo_/Y2VyZWFsMQoyCmRpY3QKZGljdAo2CnMyCmVuczQKbGFuZ2IxczYKbWFudWFsYjFzNwpwcmltYXJ5aTAKczcKdmVyc2lvbnIxCnM2Cmt3YXJnc3M3ClRWX1Nob3dzMTAKbWVkaWFfdHlwZTMKczQKMTk5OHM0CnllYXJzNwoyNDM3NjgyczIKaWRzMzAKQmFubm91IEJ1bmthIE5la29tdXN1bWUgKDE5OTgpczQKc2hvd3IwCg__
2019-12-16 18:49:36,335 (3138) :  DEBUG (runtime:49) - Received packed state data (80 bytes)
2019-12-16 18:49:36,335 (3138) :  DEBUG (runtime:814) - Found route matching /:/plugins/com.plexapp.agents.hama/messaging/function/X0FnZW50S2l0OlNlYXJjaA__/Y2VyZWFsMQoxCmxpc3QKMApyMAo_/Y2VyZWFsMQoyCmRpY3QKZGljdAo2CnMyCmVuczQKbGFuZ2IxczYKbWFudWFsYjFzNwpwcmltYXJ5aTAKczcKdmVyc2lvbnIxCnM2Cmt3YXJnc3M3ClRWX1Nob3dzMTAKbWVkaWFfdHlwZTMKczQKMTk5OHM0CnllYXJzNwoyNDM3NjgyczIKaWRzMzAKQmFubm91IEJ1bmthIE5la29tdXN1bWUgKDE5OTgpczQKc2hvd3IwCg__
2019-12-16 18:49:36,335 (3138) :  INFO (agentkit:957) - Searching for matches for {'show': 'Bannou Bunka Nekomusume (1998)', 'id': '2437682', 'year': '1998'}
2019-12-16 18:49:36,336 (3138) :  DEBUG (networking:143) - Requesting 'http://127.0.0.1:32400/library/metadata/2437682/tree'
2019-12-16 18:49:36,349 (3138) :  INFO (common:151) - ==== common.PlexLog(file="E:\Users\Toto Saurio\AppData\Local\Plex Media Server\Plug-in Support\Data\com.plexapp.agents.hama\DataItems\_Logs\Anime\Bannou Bunka Nekomusume (1998) [andib-526].agent-search.log")
2019-12-16 18:49:36,388 (3138) :  DEBUG (networking:138) - Fetching 'http://thetvdb.com/api/GetSeries.php?seriesname=Bannou%20Bunka%20Nekomusume%20(1998)' from the HTTP cache
2019-12-16 18:49:36,428 (3138) :  DEBUG (runtime:88) - Sending packed state data (104 bytes)
2019-12-16 18:49:36,428 (3138) :  DEBUG (runtime:924) - Response: [200] str, 320 bytes

EDIT: Fixed it removing the year from the filenames

@Roshri Also noticed you misspelled ā€œanidbā€ in the folder name which could be causing issues/confusion.

Will HAMA use the ā€œDVD Orderā€ in any way? Both the Plex Series Settings (Edit > Advanced > Episode Ordering) and TVDB have that option but they seem ineffective since I can’t get S00E01\DVD-13 to match a filename numbered 13 with any of the 11 [anidb#-14413] or [tvdb#-359646] suffixes.

I did request the episode to be added as Absolute #13 in TheTVDB Forums, but it was denied ā€œbecause specials don’t belong in absolute orderingā€ :roll_eyes:

I keep overall Anidb naming and I force things with anidb-id in folder name.

I have file with following path:
Mushishi Zoku Shou [anidb-10384]/Mushi-Shi∶ Next Passage - E11 - Path Of Thorns.mkv.

According to AniDB: https://anidb.net/anime/10384 the episode 11 is Path of Thorns. However, in my plex it shows up as Cushion of grass episode.

The real Cushion of grass episode with path: Mushishi Zoku Shou (2014) [anidb-10571]/Mushishi Zoku Shou (2014) - E01 - Cushion Of Grass.mkv works correctly.

I’m a bit lost what is at fault and I’m not sure where to report it, is this HAMA problem or ScudLee’s mapping list problem? I thought that anidb-id matching doesn’t use Scud’s mapping file.

I am having issues with Absolute Series Scanner and HAMA. Nothing I add can be matched at all. It just says NO MATCHES FOUND USING THIS AGENT when I try to force a match too. Does anyone know what’s going on? I would really love to get things up and running again. Anyone else having this issue?

@ZeroQI I would really appreciate any help. I tried downloading following your instructions on the GitHub forum and manually deleting and updating anime-titles.xml in Hama agent data folders Anidb… but nothing I put in my anime plex folder is matching. I try to match and immediately I get a no match found message. Something’s broken but I have no idea what it is and I’m not nearly as savvy as most people here so I don’t know how to go into the various files and search line by line for what that could be.

@eskela check agent settings, you specified anidb numbering, but metadata is crossed referenced between AniDB and TheTVDB, as per the agent setting metadata field priorities…

@plex2903 well if you can see files in plex, then the scanner works… The github readme indicate the files to include for troubleshooting. There could be an issue in latest Plex release as well.

including all the following logs: (location: https://support.plex.tv/hc/en-us/articles/200250417-Plex-Media-Server-Log-Files)

  • […]/Plex Media Server/Logs/PMS Plugin Logs/com.plexapp.agents.hama.log (Agent logs)
  • […]/Plex Media Server/Logs/PMS Plugin Logs/com.plexapp.system.log (show why the agent cannot launch)
  • […]/Plex Media Server/Plug-in Support/Data/com.plexapp.agents.hama/DataItems/_Logs/series_root_folder.filelist.log (episodes info)
  • […]/Plex Media Server/Plug-in Support/Data/com.plexapp.agents.hama/DataItems/_Logs/series_root_folder.scanner.log (episodes info)
  • […]/Plex Media Server/Plug-in Support/Data/com.plexapp.agents.hama/DataItems/_Logs/(Library_name/)series_root_folder.agent-search.log (guid assignment)
  • […]/Plex Media Server/Plug-in Support/Data/com.plexapp.agents.hama/DataItems/_Logs/(Library_name/)series_root_folder.agent-update.log (metadata update)
  • Screen capture to illustrate if needed. Above logs are still mandatory
1 Like

@ZeroQI thanks for the fast reply, I really appreciate it! Trying to diagnose this asap and get it fixed. When you say if I can see files in plex, then the scanner works… I just want to be clear – the only thing I can see in plex when I add a file to my anime folder is the file, but there’s no metadata, no poster art, nothing. It’s just the movie and it’s named according to the name of the file.

How do I share the logs you’ve requested? I’m not sure if I can copy and save them? Or how to turn them into zip files? Apologies if this is all easy to do, I am a true novice!

@ZeroQI would updating to the latest Absolute Series Scanner.py help this issue potentially? If so, I don’t understand how to do this from the readme, would you be able to help me out? Do I just delete the old .py file and drag the new one into the scanner folder? And then restart plex?

yep, that’s the way.
However, if you see the files in Plex albeit without Metadata, the scanner did its job. you can attach files with the upload icon (8th from the left when posting)…

So if the files just won’t match, do you know what the issue might be? I haven’t tried to update the ASS file yet but I’m planning to. Just wondering if that would be the cause in your opinion? If, as you say, nothing is wrong with the scanner and it’s doing its job.

My priority for title was AniDB, TheTVDB | TheTVDB, AniDB, which is default. After your response, I tried a few variants AniDB, TheTVDB, then AniDB | TheTVDB refreshing metadata after doing plexu dansu just to be safe. I didn’t understand what comma and pipe do in this config scenario and I couldn’t find it in any readme.

As I expected after your response, the title problem got resolved when I defined title as AniDB only. Thank you for your help, @ZeroQI. I had this problem across many titles, where specials got misplaced and it was driving me crazy. :triumph:

It doesn’t feel quite right as a general behaviour, though please note I’m not overly familiar with the logic behind the scanner. If anidb was listed as first then I’d expect it to take priority over tvdb, and only fall back on tvdb when it’s AniDB is clueless about the thing?

I think this will also resolve some issues with reversed seiyuu names (I have Nakamura Yuuichi and Yuuichi Nakamura), if I stick to one source of metadata for voice actors and refresh all metadata.

If priorities differs for series and episode titles, you can define priority as: series priority | episode priority.

You defined anidb numbering but it still cross references both ways to TheTVDB episodes metadata as anidb globally doesn’t have episode summaries… Is something is badly mapped you should submit a fix toit and help the community. The logging was done in the agent so mapping is easy enough to read.

However please note that for titles the language priority is primary and the source is secondary. In other words, if you say ā€˜fr’ language first it will pick the first french title in the source order then try next language

By scanner you mean the agent?

Yes it would fix seyiuu names if coming from single source. TheTVDB is per episode, anidb per series if I recall correctly

1 Like

I’m currently changing my file hierarchy.

  • From : LibraryFolder/AnimeFolders
  • To : LibraryFolder/SubCategoryFolder/AnimeFolders

Where :

  • LibraryFolder is the folder you pick while editing a library on plex.
  • SubCategoryFolder won’t be used for local collection, it’s just a low level organizer to separate movies, OAV, series, TV Special, etc.
  • AnimeFolders are all individual folder per Anime (with [anidb-XXX] tagging in the name of each folder)

On the paper everything should work fine, but is there known potential issue with hama, ASS or both for adding a layer like that ?

Oh yeah… The scanner will not use caching and scan all Everytime you scan, could lead to database corruption… At least had a couple while developing but had bugs so who knows really…
You can add subcategoryfolder as library folder ideally…

Glad I asked, I’ll add each SubCategoryFolder as library folders then. thanks for the help !

Any idea how to fix that ?

2020-02-29 13:53:17,149 (7f94feffd700) :  CRITICAL (agentkit:1078) - Exception in the update function of agent named 'HamaTV', called with guid 'com.plexapp.agents.hama://anidb-6107?lang=en' (most recent call last):
  File "/usr/lib/plexmediaserver/Resources/Plug-ins-cc260c476/Framework.bundle/Contents/Resources/Versions/2/Python/Framework/api/agentkit.py", line 1076, in _update
    agent.update(obj, media, lang, **kwargs)
  File "/var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Plug-ins/Hama.bundle/Contents/Code/__init__.py", line 180, in update
    def update (self, metadata, media, lang, force ):  Update (metadata, media, lang, force,  False)
  File "/var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Plug-ins/Hama.bundle/Contents/Code/__init__.py", line 153, in Update
    dict_AnimeLists, AniDBid, TVDBid, TMDbid, IMDbid, mappingList =  AnimeLists.GetMetadata(media, movie, error_log, metadata.id)
  File "/var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Plug-ins/Hama.bundle/Contents/Code/AnimeLists.py", line 229, in GetMetadata
    title = AniDB.GetAniDBTitle(AniDB.AniDBTitlesDB.xpath('/animetitles/anime[@aid="{}"]/title'.format(anime.get("anidbid", ""))))[0]  #returns [title, main, language_rank]
  File "/var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Plug-ins/Hama.bundle/Contents/Code/AniDB.py", line 401, in GetAniDBTitle
    if lang in languages and (type!='short' and type_priority[type] < langLevel[languages.index(lang)] or not type):  langTitles[languages.index(lang)  ], langLevel [languages.index(lang)  ] = title.text.replace("`", "'"), type_priority [ type ] if type else 6 + languages.index(lang)
  File "/usr/lib/plexmediaserver/Resources/Plug-ins-cc260c476/Framework.bundle/Contents/Resources/Versions/2/Python/Framework/code/sandbox.py", line 108, in <lambda>
    _getitem_           = lambda x, y: x.__getitem__(y),
KeyError: 'kana'

Hey guys, I’ve had an issue with the HAMA agent regarding One Piece.

When I match my OP folder using the HAMA agent, the theme song selected to play is the horrid 4kids opening. I do not want that opening but prefer the original or redone We Are opening. Is there a way to fix this issue??

I posted about this issue in this thread.