AMC anime ut_label sometimes still using TVDB

Any questions? Need some help?
Post Reply
aktersnurra95
Posts: 13
Joined: 11 May 2019, 11:13

AMC anime ut_label sometimes still using TVDB

Post by aktersnurra95 » 03 Jun 2019, 22:16

I've noticed recently some of my anime labeled files get sorted as TV show.

amc log:

Code: Select all

Run script [fn:amc] at [Mon Jun 03 14:24:13 CEST 2019]
Parameter: unsorted = y
Parameter: movieFormat = D:/Movies/{n.replaceTrailingBrackets().replaceAll(':',' -')} ({y})/{n.replaceTrailingBrackets().replaceAll(':',' -')} ({y}){' (Part '+pi+')'} [{source}-{vf} {vc} {ac}]{' ['+group+']'}{'.'+lang}
Parameter: seriesFormat = D:/Series/{n.replaceAll(':',' -')}/{'Season ' + s}/{n.replaceTrailingBrackets().replaceAll(':',' -')} ({y}) - {s00e00.lower()} - {t.replaceAll(':',' -')} [{source}-{vf} {vc} {ac} {bitdepth}bit]{' ['+group+']'}{'.'+lang}
Parameter: animeFormat = D:/Anime/{primarytitle.replaceAll(':',' -')}/{primarytitle.replaceAll(':',' -')} - {'S' + special.pad(3)}{'E' + absolute.pad(3)} - {t.replaceAll(':',' -')}{' ['+bitdepth+'bit]'}{' ['+group+']'}
Parameter: ut_label = Anime
Parameter: ut_state = 
Parameter: ut_title = [Erai-raws] Shingeki no Kyojin Season 3 (2019) - 06 [720p AVC-YUV444P10][Multiple Subtitle].mkv
Parameter: ut_kind = multi
Parameter: ut_file = 
Parameter: ut_dir = D:\Downloads\qBittorrent\Anime\[Erai-raws] Shingeki no Kyojin Season 3 (2019) - 06 [720p AVC-YUV444P10][Multiple Subtitle].mkv
Input: D:\Downloads\qBittorrent\Anime\[Erai-raws] Shingeki no Kyojin Season 3 (2019) - 06 [720p AVC-YUV444P10][Multiple Subtitle].mkv
Group: [tvs:shingeki no kyojin] => [[Erai-raws] Shingeki no Kyojin Season 3 (2019) - 06 [720p AVC-YUV444P10][Multiple Subtitle].mkv]
Rename episodes using [TheTVDB]
Auto-detected query: [Shingeki no Kyojin]
Fetching episode data for [Attack on Titan]
Fetching episode data for [Rage of Bahamut]
Fetching episode data for [Attack on Titan: Junior High]
[HARDLINK] from [D:\Downloads\qBittorrent\Anime\[Erai-raws] Shingeki no Kyojin Season 3 (2019) - 06 [720p AVC-YUV444P10][Multiple Subtitle].mkv] to [D:\Series\Attack on Titan\Season 3\Attack on Titan (2013) - s03e06 - Sin [-720p x264 AAC 10bit] [Erai-raws].mkv]
Processed 1 files
Done ヾ(@⌒ー⌒@)ノ
I don't think I can see anything wrong, but I'd appreciate a look...
Is there something going wrong out of my control or is there anything I can do to possibly fix this?

Here's my amc call via a python script:

Code: Select all

import sys
import subprocess


# configuration
output = 'D:/Downloads'


# custom formats (use / instead of \ as directory separator)
movieFormat  = "D:/Movies/{n.replaceTrailingBrackets().replaceAll(':',' -')} ({y})/{n.replaceTrailingBrackets().replaceAll(':',' -')} ({y}){' (Part '+pi+')'} [{source}-{vf} {vc} {ac}]{' ['+group+']'}{'.'+lang}"
seriesFormat = "D:/Series/{n.replaceAll(':',' -')}/{'Season ' + s}/{n.replaceTrailingBrackets().replaceAll(':',' -')} ({y}) - {s00e00.lower()} - {t.replaceAll(':',' -')} [{source}-{vf} {vc} {ac} {bitdepth}bit]{' ['+group+']'}{'.'+lang}"
animeFormat  = "D:/Anime/{primarytitle.replaceAll(':',' -')}/{primarytitle.replaceAll(':',' -')} - {'S' + special.pad(3)}{'E' + absolute.pad(3)} - {t.replaceAll(':',' -')}{' ['+bitdepth+'bit]'}{' ['+group+']'}"


# required args
label, state, title, kind, file, directory = sys.argv[1:7]


if label == 'Radarr' or label == 'Sonarr' or label == 'Other':
	print('Aborting due to label: ' + label)
	sys.exit(0)


command = [
	'filebot', '-script', 'fn:amc',
	'--output', output,
	'--action', 'hardlink',
	'--conflict', 'auto',
	'-non-strict',
	'--log-file', 'D:\Other\Filebot/amc.log',
	'--def',
		'unsorted=y',
		'movieFormat='  + movieFormat,
		'seriesFormat=' + seriesFormat,
		'animeFormat='  + animeFormat,
		'ut_label=' + label,
		'ut_state=' + state,
		'ut_title=' + title,
		'ut_kind='  + kind,
		'ut_file='  + file,
		'ut_dir='   + directory
]


# execute command (and hide cmd window)
subprocess.run(command, creationflags=0x08000000)
Thanks in advance!

devster
Posts: 335
Joined: 06 Jun 2017, 22:56

Re: AMC anime ut_label sometimes still using TVDB

Post by devster » 04 Jun 2019, 00:15

It's possible the season (Season 3) forces TheTVDB usage.

Code: Select all

	private static final Pattern SERIES_FOLDER_PATTERN = compile("TV.Shows|TV.Series|Season.\\d+", CASE_INSENSITIVE);
from https://github.com/filebot/filebot/blob ... n.java#L76 I believe
I only work in black and sometimes very, very dark grey. (Batman)

User avatar
rednoah
The Source
Posts: 16936
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: AMC anime ut_label sometimes still using TVDB

Post by rednoah » 04 Jun 2019, 02:44

1.
The category is forced in the amc script regardless of FileBot internal auto-detection code:
https://github.com/filebot/scripts/blob ... roovy#L329

Also, that pattern only applies if there's a /Season N/ folder name.


2.
Notably, if Anime is forced, then you should get this log message:

Code: Select all

Group: [Anime:true] ...
Here's what I get:

Code: Select all

filebot -script fn:amc . --action TEST --output ../OUTPUT --def minFileSize=0 -non-strict --def ut_label=Anime
Run script [fn:amc] at [Tue Jun 04 09:39:09 ICT 2019]
Parameter: minFileSize = 0
Parameter: ut_label = Anime
Argument[0]: .
Input: Anime/[Erai-raws] Shingeki no Kyojin Season 3 (2019) - 06 [720p AVC-YUV444P10][Multiple Subtitle].mkv
Group: [Anime:true] => [[Erai-raws] Shingeki no Kyojin Season 3 (2019) - 06 [720p AVC-YUV444P10][Multiple Subtitle].mkv]
Rename episodes using [AniDB] with [Absolute Order]
Auto-detected query: [Shingeki no Kyojin]
Fetching episode data for [Shingeki no Kyojin]
Fetching episode data for [Shingeki no Kyojin Season 3]
Fetching episode data for [Shingeki no Kyojin OAD]
Fetching episode data for [Shingeki no Kyojin Season 2]
Fetching episode data for [Shingeki no Kyojin Season 3 (2019)]
[TEST] from [Anime/[Erai-raws] Shingeki no Kyojin Season 3 (2019) - 06 [720p AVC-YUV444P10][Multiple Subtitle].mkv] to [../OUTPUT/Anime/Shingeki no Kyojin Season 3 (2019)/Shingeki no Kyojin Season 3 (2019) - 06 - Midnight Sun.mkv]
Processed 1 files
Done ヾ(@⌒ー⌒@)ノ
Note that if you're using the latest from GitHub, then it'll default to using TheTVDB with Absolute Order instead of AniDB:

Code: Select all

filebot -script dev:amc . --action TEST --output ../OUTPUT --def minFileSize=0 -non-strict --def ut_label=Anime
Run script [dev:amc] at [Tue Jun 04 09:39:39 ICT 2019]
Parameter: minFileSize = 0
Parameter: ut_label = Anime
Argument[0]: .
Input: Anime/[Erai-raws] Shingeki no Kyojin Season 3 (2019) - 06 [720p AVC-YUV444P10][Multiple Subtitle].mkv
Group: [Anime:true] => [[Erai-raws] Shingeki no Kyojin Season 3 (2019) - 06 [720p AVC-YUV444P10][Multiple Subtitle].mkv]
Rename episodes using [TheTVDB] with [Absolute Order]
Auto-detected query: [Shingeki no Kyojin]
Fetching episode data for [Attack on Titan]
[TEST] from [Anime/[Erai-raws] Shingeki no Kyojin Season 3 (2019) - 06 [720p AVC-YUV444P10][Multiple Subtitle].mkv] to [../OUTPUT/Anime/Attack on Titan/Attack on Titan - 06 - The World the Girl Saw - The Struggle for Trost, Part 2.mkv]
Processed 1 files
Done ヾ(@⌒ー⌒@)ノ
:!: TheTVDB / Absolute is sometimes a better choice. But it's a bad choice in this case. We'll see how it goes for a while, and then maybe revert to always use AniDB by default, if that does work better in the end.
:idea: Please read the FAQ and How to Request Help.

aktersnurra95
Posts: 13
Joined: 11 May 2019, 11:13

Re: AMC anime ut_label sometimes still using TVDB

Post by aktersnurra95 » 04 Jun 2019, 08:56

Hmm.. What would cause me to not get [anime:true]?
I don't have the TVDB absolute, since other anime episodes get processed correctly with anime format and using AniDb.
Attack on Titan s3 p2 seems to be the main culprit for me atm..
Is the [anime:true] parameter only when anime gets forced or also when auto detected? I'll have to check if my other files get forced or only detected.

Will check after work today. Thanks!

aktersnurra95
Posts: 13
Joined: 11 May 2019, 11:13

Re: AMC anime ut_label sometimes still using TVDB

Post by aktersnurra95 » 04 Jun 2019, 11:27

Here is what a successful anime rename looks like:

Code: Select all

Run script [fn:amc] at [Wed May 29 17:51:57 CEST 2019]
Parameter: unsorted = y
Parameter: movieFormat = D:/Movies/{n.replaceTrailingBrackets().replaceAll(':',' -')} ({y})/{n.replaceTrailingBrackets().replaceAll(':',' -')} ({y}){' (Part '+pi+')'}{'.'+lang}
Parameter: seriesFormat = D:/Series/{n.replaceAll(':',' -')}/{'Season ' + s}/{n.replaceTrailingBrackets().replaceAll(':',' -')} ({y}) - {s00e00.lower()} - {t.replacePart(' (Part \$1)').replaceAll(':',' -')}{'.'+lang}
Parameter: animeFormat = D:/Anime/{primarytitle.replaceAll(':',' -')}/{primarytitle.replaceAll(':',' -')} - {'S' + special.pad(3)}{'E' + absolute.pad(3)} - {t.replacePart(' (Part)').replaceAll(':',' -')}{' ['+group+']'}
Parameter: ut_label = Anime
Parameter: ut_state = 
Parameter: ut_title = [HorribleSubs] Kenja no Mago - 08 [720p].mkv
Parameter: ut_kind = multi
Parameter: ut_file = 
Parameter: ut_dir = D:\Downloads\qBittorrent\Anime\[HorribleSubs] Kenja no Mago - 08 [720p].mkv
Input: D:\Downloads\qBittorrent\Anime\[HorribleSubs] Kenja no Mago - 08 [720p].mkv
Group: [anime:kenja no mago] => [[HorribleSubs] Kenja no Mago - 08 [720p].mkv]
Rename episodes using [AniDB]
Auto-detected query: [Kenja no Mago]
Fetching episode data for [Kenja no Mago]
[HARDLINK] from [D:\Downloads\qBittorrent\Anime\[HorribleSubs] Kenja no Mago - 08 [720p].mkv] to [D:\Anime\Kenja no Mago\Kenja no Mago - E008 - Episode 8 [HorribleSubs].mkv]
Processed 1 files
Done ヾ(@⌒ー⌒@)ノ
Group: [anime:kenja no mago] is the output I get, for any show/movie it will say [type:title], I couldn't spot any [type:true] throughout my logs.

That to me seems like its still automatching even though it gets a label... but I wouldn't know...

User avatar
rednoah
The Source
Posts: 16936
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: AMC anime ut_label sometimes still using TVDB

Post by rednoah » 04 Jun 2019, 12:11

1.
Please run filebot -script fn:sysinfo and post the output.

2.
I'm using the latest beta release:
https://get.filebot.net/filebot/BETA/
:idea: Please read the FAQ and How to Request Help.

aktersnurra95
Posts: 13
Joined: 11 May 2019, 11:13

Re: AMC anime ut_label sometimes still using TVDB

Post by aktersnurra95 » 04 Jun 2019, 14:41

Here's the sysinfo. I see I have an update, I'll check if updating helps the issue.

Code: Select all

filebot -script fn:sysinfo
FileBot 4.8.2 (r5789)
JNA Native: 5.2.2
MediaInfo: 18.05
7-Zip-JBinding: 9.20
Chromaprint: 1.4.2
Extended Attributes: OK
Unicode Filesystem: OK
Script Bundle: 2019-02-26 (r552)
Groovy: 2.5.1
JRE: Java(TM) SE Runtime Environment 10.0.2
JVM: 64-bit Java HotSpot(TM) 64-Bit Server VM
CPU/MEM: 2 Core / 1010 MB Max Memory / 42 MB Used Memory
OS: Windows 10 (amd64)
Package: MSI
License: FileBot License P6008659 (Valid-Until: 2019-10-25)

------------------- UPDATE AVAILABLE: FileBot 4.8.5 (r6224) --------------------

Done ?(?????)?

aktersnurra95
Posts: 13
Joined: 11 May 2019, 11:13

Re: AMC anime ut_label sometimes still using TVDB

Post by aktersnurra95 » 04 Jun 2019, 15:20

Well... seems on a quick glance that updating solved the issue.

Code: Select all

Run script [fn:amc] at [Tue Jun 04 17:00:46 CEST 2019]
Parameter: unsorted = y
Parameter: movieFormat = D:/Movies/{n.replaceTrailingBrackets().replaceAll(':',' -')} ({y})/{n.replaceTrailingBrackets().replaceAll(':',' -')} ({y}){' (Part '+pi+')'} [{source}-{vf} {vc} {ac}]{' ['+group+']'}{'.'+lang}
Parameter: seriesFormat = D:/Series/{n.replaceAll(':',' -')}/{'Season ' + s}/{n.replaceTrailingBrackets().replaceAll(':',' -')} ({y}) - {s00e00.lower()} - {t.replaceAll(':',' -')} [{source}-{vf} {vc} {ac} {bitdepth}bit]{' ['+group+']'}{'.'+lang}
Parameter: animeFormat = D:/Anime/{primarytitle.replaceAll(':',' -')}/{primarytitle.replaceAll(':',' -')} - {'S' + special.pad(3)}{'E' + absolute.pad(3)} - {t.replaceAll(':',' -')}{' ['+bitdepth+'bit]'}{' ['+group+']'}
Parameter: ut_label = Anime
Parameter: ut_state = 
Parameter: ut_title = [Erai-raws] Shingeki no Kyojin Season 3 (2019) - 06 [720p AVC-YUV444P10][Multiple Subtitle].mkv
Parameter: ut_kind = multi
Parameter: ut_file = 
Parameter: ut_dir = D:\Downloads\qBittorrent\Anime\[Erai-raws] Shingeki no Kyojin Season 3 (2019) - 06 [720p AVC-YUV444P10][Multiple Subtitle].mkv
Activate License P6008659
Input: D:\Downloads\qBittorrent\Anime\[Erai-raws] Shingeki no Kyojin Season 3 (2019) - 06 [720p AVC-YUV444P10][Multiple Subtitle].mkv
xattr: [[Erai-raws] Shingeki no Kyojin Season 3 (2019) - 06 [720p AVC-YUV444P10][Multiple Subtitle].mkv] => [Attack on Titan - 3x06 - Sin]
Group: [Anime:true] => [[Erai-raws] Shingeki no Kyojin Season 3 (2019) - 06 [720p AVC-YUV444P10][Multiple Subtitle].mkv]
Rename episodes using [AniDB]
Auto-detected query: [Attack on Titan]
Fetching episode data for [Shingeki no Kyojin]
Fetching episode data for [Shingeki no Kyojin OAD]
Fetching episode data for [Shingeki no Kyojin Season 2]
Fetching episode data for [Shingeki no Kyojin Season 3]
Fetching episode data for [Shingeki no Kyojin Season 3 (2019)]
[HARDLINK] from [D:\Downloads\qBittorrent\Anime\[Erai-raws] Shingeki no Kyojin Season 3 (2019) - 06 [720p AVC-YUV444P10][Multiple Subtitle].mkv] to [D:\Anime\Shingeki no Kyojin Season 3\Shingeki no Kyojin Season 3 - E006 - Sin [10bit] [Erai-raws].mkv]
Processed 1 files
Done ヾ(@⌒ー⌒@)ノ
I now get Group: [Anime:true] and it works mostly as it should, I think the xattr might have caused it to detect as s3 p1!

Thanks for the help @Rednoah!
Thank you @Devster too!

EDIT: Yup, running a file without any xattr worked flawlessly!
Thanks again!

Post Reply