[amc] Illegal state: 12 != 11

Running FileBot from the console, Groovy scripting, shell scripts, etc
Post Reply
simondsmason
Posts: 2
Joined: 23 Feb 2019, 14:15

[amc] Illegal state: 12 != 11

Post by simondsmason »

I am running filebot on torrent change in uTorrent. I found a poster that had configured a command line that I copied and used as my starting point.

This is what I am running in uTorrent:

Code: Select all

"C:\Program Files\FileBot\filebot.launcher.exe" -script fn:amc --action move -non-strict -no-xattr --log-file "E:/Torrent Downloads/amc.log" --filter "any{episode; age < 92}{true}" --def "@E:/Torrent Downloads/amc_args.txt" "ut_label=%L" "ut_state=%S" "ut_title=%N" "ut_kind=%K" "ut_file=%F" "ut_dir=%D"
My amc.args is as follows:

Code: Select all

ut_state_allow=11
unsorted=n
music=n
artwork=n
extras=n
skipExtract=y
clean=y
seriesFormat=V:/TV Shows/{n.sortName('$2, $1').replaceTrailingBrackets()}/{s00e00} {t.replaceAll(/[!?.]+$/).replaceAll(/[`´‘’?]/, "'").lowerTrail()}
movieFormat=U:/Plex Video Folders/Movies/{n.sortName('$2, $1').lowerTrail()} ({y}) {vf} {ac.replace('AC3','DD')}{af.replace('6ch','5.1').replace('2ch','2.0')}
So far I have downloaded two TV shows and this is what I am getting in the log file:

Code: Select all

Run script [fn:amc] at [Mon Feb 18 02:17:40 EST 2019]
Parameter: ut_state_allow = 11
Parameter: unsorted = n
Parameter: music = n
Parameter: artwork = n
Parameter: extras = n
Parameter: skipExtract = y
Parameter: clean = y
Parameter: seriesFormat = V:/TV Shows/{n.sortName('$2, $1').replaceTrailingBrackets()}/{s00e00} {t.replaceAll(/[!?.]+$/).replaceAll(/[`´‘’?]/, "'").lowerTrail()}
Parameter: movieFormat = U:/Plex Video Folders/Movies/{n.sortName('$2, $1').lowerTrail()} ({y}) {vf} {ac.replace('AC3','DD')}{af.replace('6ch','5.1').replace('2ch','2.0')}
Parameter: ut_label = 
Parameter: ut_state = 21
Parameter: ut_title = Madam.Secretary.S05E14.HDTV.x264-KILLERS[ettv]
Parameter: ut_kind = multi
Parameter: ut_file = Downloaded from www.ETTV.tv .txt
Parameter: ut_dir = E:\Torrent Downloads\Madam.Secretary.S05E14.HDTV.x264-KILLERS[ettv]
Illegal state: 21 != 11
Failure (°_°)
Run script [fn:amc] at [Fri Feb 22 00:45:27 EST 2019]
Parameter: ut_state_allow = 11
Parameter: unsorted = n
Parameter: music = n
Parameter: artwork = n
Parameter: extras = n
Parameter: skipExtract = y
Parameter: clean = y
Parameter: seriesFormat = V:/TV Shows/{n.sortName('$2, $1').replaceTrailingBrackets()}/{s00e00} {t.replaceAll(/[!?.]+$/).replaceAll(/[`´‘’?]/, "'").lowerTrail()}
Parameter: movieFormat = U:/Plex Video Folders/Movies/{n.sortName('$2, $1').lowerTrail()} ({y}) {vf} {ac.replace('AC3','DD')}{af.replace('6ch','5.1').replace('2ch','2.0')}
Parameter: ut_label = 
Parameter: ut_state = 12
Parameter: ut_title = Star.Trek.Discovery.S02E06.WEBRip.x264-TBS[ettv]
Parameter: ut_kind = multi
Parameter: ut_file = 
Parameter: ut_dir = E:\Torrent Downloads
Illegal state: 12 != 11
Failure (°_°)
I am not sure what the garbage characters are after the replaceAll?

Can someone provide some pointers on how to diagnose this? Thanks.

Running on Windows 10, sysinfo below:

Code: Select all

E:\Torrent Downloads>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-08 (r546)
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: 4 Core / 1 GB Max Memory / 54 MB Used Memory
OS: Windows 10 (amd64)
Package: MSI
License: FileBot License P7014982 (Valid-Until: 2020-02-24)
Done ?(?????)?
User avatar
rednoah
The Source
Posts: 22974
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: Newbie - Just started using filebot and need help

Post by rednoah »

1.
Looks like it's doing what it's supposed to be doing.

You are explicitly instructing FileBot to only process files if uT passes in a specific state. Is this something you're doing for some particular purpose?

Code: Select all

Parameter: ut_state_allow = 11
Parameter: ut_state = 12

Code: Select all

Illegal state: 12 != 11

Note that this is a hidden feature neither recommended nor documented in the official manual:
viewtopic.php?f=4&t=215



2.
I recommend starting with the official examples, and then making changes for your particular needs as these needs arise, meaning you'll know what you're doing every step of the way.

e.g.

Code: Select all

filebot -script fn:amc --output "X:/Media" --action duplicate --conflict skip -non-strict --log-file amc.log --def unsorted=y music=y artwork=y "ut_label=%L" "ut_state=%S" "ut_title=%N" "ut_kind=%K" "ut_file=%F" "ut_dir=%D"
:!: --output is required.

:!: --action move won't work on Windows since FileBot can't delete files that are being seeded by uT. Use --action duplicate instead, which will create hardlinks as long as you keep files on the same filesystem.
:idea: Please read the FAQ and How to Request Help.
simondsmason
Posts: 2
Joined: 23 Feb 2019, 14:15

Re: [amc] Illegal state: 12 != 11

Post by simondsmason »

Got it - thanks. I went back and rebuilt the commands as you suggested and it works well. I was sucked in by the promise of a (allegedly) pre-built command-line that was "ready" to go!
User avatar
rednoah
The Source
Posts: 22974
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: [amc] Illegal state: 12 != 11

Post by rednoah »

Ideally, that's how it works.

But sometimes things that work perfectly for one person don't work for another. :lol:
:idea: Please read the FAQ and How to Request Help.
Post Reply