amc script for judging Movie or TV has something wrong

Running FileBot from the console, Groovy scripting, shell scripts, etc
Post Reply
xuewy
Posts: 13
Joined: 06 Mar 2019, 14:06

amc script for judging Movie or TV has something wrong

Post by xuewy »

My filebot sysinfo is as below:

Code: Select all

root@Emby:~# filebot -script fn:sysinfo
FileBot 4.8.5 (r6196)
JNA Native: 4.0.1
MediaInfo: 0.7.91
p7zip: java.io.IOException: Cannot run program "7z": error=2, No such file or directory
Chromaprint: 1.4.3
Extended Attributes: OK
Unicode Filesystem: OK
Script Bundle: 2019-03-01 (r555)
Groovy: 2.5.6
JRE: OpenJDK Runtime Environment 11.0.2-BellSoft
JVM: 64-bit OpenJDK 64-Bit Server VM
CPU/MEM: 4 Core / 462 MB Max Memory / 25 MB Used Memory
OS: Linux (aarch64)
HW: Linux Emby 4.20.5-aml-s905 #5.75 SMP PREEMPT Mon Feb 11 14:50:02 MSK 2019 aarch64 GNU/Linux
DATA: /root/.filebot
Package: DEB
License: FileBot License P****** (Valid-Until: 2020-03-15)
Now I run the filebot command as below :

Code: Select all

filebot -script fn:amc --output "/share/Complete" --action move --conflict skip -non-strict "/share/Complete/Temp" --log-file amc.log -no-xattr --def unsorted=y excludeList=amc.txt seriesFormat="{plex}" movieFormat="{plex}" clena=y
I downloaded a movie, named [一吻定情.Fall.in.Love.at.First.Kiss.2019.HD720P.X264.AAC.Mandarin.CHS.mp4]
this is the log of my 1st time running the script:

Code: Select all

Run script [fn:amc] at [Fri Mar 15 02:34:31 UTC 2019]
Parameter: unsorted = y
Parameter: clean = y
Parameter: excludeList = amc.txt
Parameter: movieFormat = {plex}
Parameter: seriesFormat = {plex}
Argument[0]: /share/Complete/Temp
Use excludes: /share/Complete/amc.txt
Input: /share/Complete/Temp/一吻定情.Fall.in.Love.at.First.Kiss.2019.HD720P.X264.AAC.Mandarin.CHS.mp4
Group: [Movie:null, Series:一吻定情] => [一吻定情.Fall.in.Love.at.First.Kiss.2019.HD720P.X264.AAC.Mandarin.CHS.mp4]
Rename episodes using [TheTVDB]
Auto-detected query: [一吻定情]
Resource not found: https://api.thetvdb.com/search/series?name=%E4%B8%80%E5%90%BB%E5%AE%9A%E6%83%85
Fetching episode data for [Mischievous Kiss: Love in Tokyo]
[MOVE] from [/share/Complete/Temp/一吻定情.Fall.in.Love.at.First.Kiss.2019.HD720P.X264.AAC.Mandarin.CHS.mp4] to [/share/Complete/TV Shows/Mischievous Kiss - Love in Tokyo/Season 02/Mischievous Kiss - Love in Tokyo - S02E10 - Naoki's First Homecoming.mp4]
Processed 1 files
Clean clutter files and empty folders
Done ヾ(@⌒ー⌒@)ノ
Then I removed Chinese Characters and renamed as [Fall.in.Love.at.First.Kiss.2019.HD720P.X264.AAC.Mandarin.CHS.mp4], run the amc script again

Code: Select all

Run script [fn:amc] at [Fri Mar 15 02:38:04 UTC 2019]
Parameter: unsorted = y
Parameter: clean = y
Parameter: excludeList = amc.txt
Parameter: movieFormat = {plex}
Parameter: seriesFormat = {plex}
Argument[0]: /share/Complete/Temp
Use excludes: /share/Complete/amc.txt (1)
Input: /share/Complete/Temp/Fall.in.Love.at.First.Kiss.2019.HD720P.X264.AAC.Mandarin.CHS.mp4
Group: [Movie:null, Series:fall] => [Fall.in.Love.at.First.Kiss.2019.HD720P.X264.AAC.Mandarin.CHS.mp4]
Rename episodes using [TheTVDB]
Auto-detected query: [Fall]
Fetching episode data for [The Fall]
Fetching episode data for [Freefall]
Fetching episode data for [Freefall]
Fetching episode data for [Fallen]
Fetching episode data for [Fallet]
[MOVE] from [/share/Complete/Temp/Fall.in.Love.at.First.Kiss.2019.HD720P.X264.AAC.Mandarin.CHS.mp4] to [/share/Complete/TV Shows/The Fall/Season 01/The Fall - S01E01 - Episode 1.mp4]
Processed 1 files
Clean clutter files and empty folders
Done ヾ(@⌒ー⌒@)ノ
Both two times that amc script could not judge it is a movie but as a TV, then I download the scripts of 2018.10 from Github to my box and run the command from local:
this is the log:

Code: Select all

root@Emby:~# filebot -script /root/scripts/amc.groovy --output "/share/Complete" --action move --conflict skip -non-strict "/share/Complete/Temp" --log-file amc.log -no-xattr --def unsorted=y excludeList=amc.txt seriesFormat="{plex}" movieFormat="{plex}" clena=y
Locking /root/.filebot/logs/amc.log
Run script [/root/scripts/amc.groovy] at [Fri Mar 15 02:59:35 UTC 2019]
Parameter: unsorted = y
Parameter: excludeList = amc.txt
Parameter: seriesFormat = {plex}
Parameter: movieFormat = {plex}
Parameter: clena = y
Argument[0]: /share/Complete/Temp
Use excludes: /share/Complete/amc.txt (1)
Input: /share/Complete/Temp/Fall.in.Love.at.First.Kiss.2019.HD720P.X264.AAC.Mandarin.CHS.mp4
Group: [mov:fall in love at first kiss 2019] => [Fall.in.Love.at.First.Kiss.2019.HD720P.X264.AAC.Mandarin.CHS.mp4]
Rename movies using [TheMovieDB]
Auto-detect movie from context: [/share/Complete/Temp/Fall.in.Love.at.First.Kiss.2019.HD720P.X264.AAC.Mandarin.CHS.mp4]
[MOVE] from [/share/Complete/Temp/Fall.in.Love.at.First.Kiss.2019.HD720P.X264.AAC.Mandarin.CHS.mp4] to [/share/Complete/Movies/Fall in Love at First Kiss (2019)/Fall in Love at First Kiss (2019).mp4]
Processed 1 files
Done ヾ(@⌒ー⌒@)ノ
This time it works fine, why the latest amc script from Internet could not judge it's a movie or TV while the old script can do. There must be something wrong in the latest script, could you have a look?

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

Re: amc script for judging Movie or TV has something wrong

Post by rednoah »

1.
The TV Series 一吻定情 (2013) seems to be throwing things off:
https://www.thetvdb.com/series/mischiev ... s-in-tokyo

The main reason it doesn't work is probably because TV Show 一吻定情 (2013) is indexed, but Movie 一吻定情 (2019) isn't yet. Kinda like if I said "Avatar" and you think the movie, except maybe they released a new TV show last week that you didn't know about yet.

:?: Why does an older version work better in this particular case? Probably by accident more than anything. I'll look into it though.


2.
As always, forcing TV Show / Movie Mode is highly recommended:

Code: Select all

--def ut_label=Movie


EDIT:

:!: I'll add some heuristics to mostly ignore 1900..2099 potential SxE matches.
:idea: Please read the FAQ and How to Request Help.
Post Reply