Page 1 of 1

[Error] Processing 3 unsorted files | Illegal parameter: map

Posted: 15 Jan 2017, 02:46
by jefzo
Hi Guy !
I just updated Filbot to the last version ( 4.7.7) on Debian.
Everything worked well before I update but Now I have some issue to moving unsorted files.

----------------------------
My Script :
-----------------------------
#!/bin/bash
filebot -script fn:amc --output "/mnt/Media/Media/00.A_VOIR.00" --lang en --log all --log-file amc.log --def excludeList=.fichier-traite.txt --action move --conflict auto -non-strict --def reportError=y --def unsorted=y "ut_dir=/mnt/Media/Finished" "ut_kind=multi" "ut_title=$TR_TORRENT_NAME" --def clean=y --def music=y
-----------------------------

------------------------------
The Log :
-----------------------------
Unable to differentiate: [Les Comiques Antillais - Les poids lourds du rire.avi] => [null] VS [null]
Group: [:] => [Comiques Antillais Jean-Yves Rupert En One Man Show Dvdrip French 2.avi, Comiques Antillais Jean-Yves Rupert En One Man Show Dvdrip French.avi, Les Comiques Antillais - Les poids lourds du rire.avi]
Processing 3 unsorted files
Illegal parameter: map
java.lang.IllegalArgumentException: Illegal parameter: map
at net.filebot.cli.ScriptShellBaseClass.lambda$getArgumentBean$1(ScriptShellBaseClass.java:470)
at net.filebot.cli.ScriptShellBaseClass.getArgumentBean(ScriptShellBaseClass.java:464)
at net.filebot.cli.ScriptShellBaseClass.rename(ScriptShellBaseClass.java:346)
at Script1.run(Script1.groovy:491)
at net.filebot.cli.ScriptShell.evaluate(ScriptShell.java:64)
at net.filebot.cli.ScriptShell.runScript(ScriptShell.java:74)
at net.filebot.cli.ArgumentProcessor.runScript(ArgumentProcessor.java:113)
at net.filebot.cli.ArgumentProcessor.run(ArgumentProcessor.java:30)
at net.filebot.Main.main(Main.java:120)
Caused by: java.lang.NoSuchFieldException: map
at net.filebot.cli.ScriptShellBaseClass.lambda$getArgumentBean$1(ScriptShellBaseClass.java:466)
... 8 more

Failure (°_°)
----------------------------

----------------------------
My Config :
----------------------------
FileBot 4.7.7 (r4678)
JNA Native: 4.0.1
MediaInfo: 0.7.88
7-Zip-JBinding: 9.20
Chromaprint: 1.1.0
Extended Attributes: OK
java.lang.IllegalArgumentException: /gvfs is not a valid directory
GVFS: OK
Script Bundle: 2017-01-05 (r470)
Groovy: 2.4.7
JRE: Java(TM) SE Runtime Environment 1.8.0_111
JVM: 64-bit Java HotSpot(TM) 64-Bit Server VM
CPU/MEM: 1 Core / 989 MB Max Memory / 9 MB Used Memory
OS: Linux (amd64)
Package: DEB
Data: /root/.filebot
uname: Linux jefzo-filebot 3.16.0-4-amd64 #1 SMP Debian 3.16.7-ckt20-1+deb8u1 (2015-12-14) x86_64 GNU/Linux
Done ヾ(@⌒ー⌒@)ノ
---------------------------------------


Thanks a lot for your return.

Re: [Error] Processing 3 unsorted files | Illegal parameter: map

Posted: 15 Jan 2017, 08:01
by rednoah
Looks like that feature is completely broken in 4.7.7 internally.

Fixed with r4715.

Re: [Error] Processing 3 unsorted files | Illegal parameter: map

Posted: 15 Jan 2017, 11:21
by jefzo
8-) 8-) 8-) 8-) 8-) 8-) 8-)
So Great !
Thank You rednoah !
Problem Fixed

to be honest I wasn't expected a reply as faster ...
Thanks Again
;) ;) ;) ;)

Re: [Error] Processing 3 unsorted files | Illegal parameter: map

Posted: 22 Jan 2017, 03:21
by whereswaller
Hi rednoah,
Appreciate your great support as always. I'm using v4.7.8, downloaded today.

Previously, when using the amc script, any files that met the "Ignore" criteria would be moved to [root directory]/Unsorted/ (but not renamed).

However, this functionality is no longer behaving in this way. Instead, the files meeting the "ignore" criteria are not moved at all. Has the script changed?

Older Release Log Sample:

Code: Select all

Parameter: music = y
Parameter: subtitles = en
Parameter: artwork = n
Parameter: plex = localhost
Parameter: pushbullet = *****
Parameter: reportError = y
Parameter: clean = y
Parameter: unsorted = y
Parameter: ignore = (?i)Frontline|Horizon|Khloe|Khloé|UFC
Parameter: ut_label = other
Parameter: ut_state = 20
Parameter: ut_title = UFC Fight Night 66 Edgar vs Faber 2015 05 16 HDTV x264-NWCHD -={SPARROW}=-
Parameter: ut_kind = multi
Parameter: ut_file = UFC.Fight.Night.66.Edgar.vs.Faber.2015.05.16.HDTV.x264-NWCHD.mp4
Parameter: ut_dir = C:\Users\James\Downloads\Complete\other\UFC Fight Night 66 Edgar vs Faber 2015 05 16 HDTV x264-NWCHD -={SPARROW}=-
Parameter: seriesFormat = I:/Television/{n.upperInitial()}/{'Season '+s.pad(2)}/{n.upperInitial()} {s.pad(2)}x{es*.pad(2).join('-')} - {t.upperInitial().replacePart(replacement = ', Part $1')}
Parameter: animeFormat = J:/Anime/{n.upperInitial()}/{fn}
Parameter: movieFormat = J:/Film/{y}/{allOf{info.OriginalName.upperInitial()}{n.upperInitial()}.unique().join(' - ')} {'('+y+')'} {'(Part '+pi+' of '+pn+')'}
Parameter: musicFormat = J:/Music (Unsorted)/{artist.upperInitial()}/{'('+y+') '}{album.upperInitial()}/{artist.upperInitial()} - {t.upperInitial()}
Input: C:\Users\James\Downloads\Complete\other\UFC Fight Night 66 Edgar vs Faber 2015 05 16 HDTV x264-NWCHD -={SPARROW}=-\UFC.Fight.Night.66.Edgar.vs.Faber.2015.05.16.HDTV.x264-NWCHD.mp4
Exclude: C:\Users\James\Downloads\Complete\other\UFC Fight Night 66 Edgar vs Faber 2015 05 16 HDTV x264-NWCHD -={SPARROW}=-\Torrent Downloaded From ExtraTorrent.cc.txt
Group: [:] => [UFC.Fight.Night.66.Edgar.vs.Faber.2015.05.16.HDTV.x264-NWCHD.mp4]
Get [English] subtitles for 1 files
May 30, 2015 2:30:21 PM java.util.prefs.WindowsPreferences <init>
WARNING: Could not open/create prefs root node Software\JavaSoft\Prefs at root 0x80000002. Windows RegCreateKeyEx(...) returned error code 5.
Looking up subtitles by hash via OpenSubtitles
No matching subtitles found: C:\Users\James\Downloads\Complete\other\UFC Fight Night 66 Edgar vs Faber 2015 05 16 HDTV x264-NWCHD -={SPARROW}=-\UFC.Fight.Night.66.Edgar.vs.Faber.2015.05.16.HDTV.x264-NWCHD.mp4
Processing 1 unsorted files
[COPY] Rename [C:\Users\James\Downloads\Complete\other\UFC Fight Night 66 Edgar vs Faber 2015 05 16 HDTV x264-NWCHD -={SPARROW}=-\UFC.Fight.Night.66.Edgar.vs.Faber.2015.05.16.HDTV.x264-NWCHD.mp4] to [C:\Users\James\Downloads\Unsorted\UFC.Fight.Night.66.Edgar.vs.Faber.2015.05.16.HDTV.x264-NWCHD.mp4]
Processed 1 files
Notify Plex: localhost
http://localhost:32400/library/sections/all/refresh
Sending PushBullet report
Done ヾ(@⌒ー⌒@)ノ
v4.7.7 Release Log Sample:

Code: Select all

Run script [fn:amc] at [Sun Jan 22 13:51:30 AEDT 2017]
Parameter: music = y
Parameter: subtitles = en
Parameter: artwork = n
Parameter: plex = *****
Parameter: pushbullet = *****
Parameter: reportError = y
Parameter: clean = y
Parameter: unsorted = y
Parameter: ignore = (?i)Frontline|Air Crash|Horizon|Khloe|Khloé|UFC
Parameter: ut_label = television
Parameter: ut_state = 20
Parameter: ut_title = Frontline.S35E06.Divided.States.of.America.HDTV.x264-[NY2] - [SRIGGA]
Parameter: ut_kind = multi
Parameter: ut_file = Torrent Downloaded From ExtraTorrent.cc.txt
Parameter: ut_dir = C:\Users\James\Downloads\Complete\television\Frontline.S35E06.Divided.States.of.America.HDTV.x264-[NY2] - [SRIGGA]
Parameter: seriesFormat = I:/Television/{n.upperInitial()}/{'Season '+s.pad(2)}/{n.upperInitial()} {s.pad(2)}x{es*.pad(2).join('-')} - {t.upperInitial().replacePart(replacement = ', Part $1')}
Parameter: animeFormat = J:/Anime/{n.upperInitial()}/{fn}
Parameter: movieFormat = J:/Film/{y}/{allOf{info.OriginalName.upperInitial()}{n.upperInitial()}.unique().join(' - ')} {'('+y+')'} {'(Part '+pi+' of '+pn+')'}
Parameter: musicFormat = J:/Music (Unsorted)/{artist.upperInitial()}/{'('+y+') '}{album.upperInitial()}/{artist.upperInitial()} - {t.upperInitial()}
Ignore pattern: C:\Users\James\Downloads\Complete\television\Frontline.S35E06.Divided.States.of.America.HDTV.x264-[NY2] - [SRIGGA]
No files selected for processing
Done ヾ(@⌒ー⌒@)ノ
v4.7.8 Release Log Sample:

Code: Select all

Run script [fn:amc] at [Sun Jan 22 14:41:37 AEDT 2017]
Parameter: music = y
Parameter: subtitles = en
Parameter: artwork = n
Parameter: plex = *****
Parameter: pushbullet = *****
Parameter: reportError = y
Parameter: clean = y
Parameter: unsorted = y
Parameter: ignore = (?i)Frontline|Air Crash|Horizon|Khloe|Khloé|UFC
Parameter: ut_label = television
Parameter: ut_state = 8
Parameter: ut_title = Frontline.S35E06.Divided.States.of.America.HDTV.x264-[NY2] - [SRIGGA]
Parameter: ut_kind = multi
Parameter: ut_file = Torrent Downloaded From ExtraTorrent.cc.txt
Parameter: ut_dir = C:\Users\James\Downloads\Complete\television\Frontline.S35E06.Divided.States.of.America.HDTV.x264-[NY2] - [SRIGGA]
Parameter: seriesFormat = I:/Television/{n.upperInitial()}/{'Season '+s.pad(2)}/{n.upperInitial()} {s.pad(2)}x{es*.pad(2).join('-')} - {t.upperInitial().replacePart(replacement = ', Part $1')}
Parameter: animeFormat = J:/Anime/{n.upperInitial()}/{fn}
Parameter: movieFormat = J:/Film/{y}/{allOf{info.OriginalName.upperInitial()}{n.upperInitial()}.unique().join(' - ')} {'('+y+')'} {'(Part '+pi+' of '+pn+')'}
Parameter: musicFormat = J:/Music (Unsorted)/{artist.upperInitial()}/{'('+y+') '}{album.upperInitial()}/{artist.upperInitial()} - {t.upperInitial()}
Ignore pattern: C:\Users\James\Downloads\Complete\television\Frontline.S35E06.Divided.States.of.America.HDTV.x264-[NY2] - [SRIGGA]
No files selected for processing
Done ヾ(@⌒ー⌒@)ノ

Re: [Error] Processing 3 unsorted files | Illegal parameter: map

Posted: 22 Jan 2017, 07:06
by rednoah
Yes, the --def ignore causes files to be completely ignored now. Ignored files being sorted into unsorted was more of a bug then a feature in older versions.

EDIT:

If you want to force files to be sorted into unsorted, then you need to pass in --def ut_label=other.

Re: [Error] Processing 3 unsorted files | Illegal parameter: map

Posted: 26 Jan 2017, 14:12
by whereswaller
Hi rednoah,
Appreciate the feedback. I'm keen to follow your advice and use "ut_label=other" to achieve the previous unsorted functionality.

How do override "ut_label=%L" in the amc script for only those files with names meeting my previous unsorted criteria? Can if statements be used in the amc script? If not, can two --filter functions be used in the one amc script and, if so, how do I distinguish between the sections of the code applicable to the first and second filter?

Error Causing AMC Modification Attempt 1 (If Statement):

Code: Select all

{n = (?i)Frontline|Air Crash|Horizon|Khloe|Khloé|UFC ? "ut_label=other" : "ut_label=%L"}
Error Causing AMC Modification Attempt 2 (2 Filter Functions):

Code: Select all

--filter "n = (?i)Frontline|Air Crash|Horizon|Khloe|Khloé|UFC" --def "ut_label=other" --filter "n != (?i)Frontline|Air Crash|Horizon|Khloe|Khloé|UFC" --def "ut_label=%L"
Current AMC Script:

Code: Select all

filebot.launcher.exe -script fn:amc --output "C:/Users/James/Downloads" --log-file amc.log --action copy --conflict skip -non-strict --def music=y subtitles=en artwork=n --def plex=localhost --def pushbullet=XKGdtNocBxdADepDy30ptyWFHrVW6E8I --def clean=y --def unsorted=y --def ignore "(?i)Frontline|Air Crash|Horizon|Khloe|Khloé|UFC" --def "ut_label=%L" "ut_state=%S" "ut_title=%N" "ut_kind=%K" "ut_file=%F" "ut_dir=%D" --def "seriesFormat=I:/Television/{n.upperInitial()}/{'Season '+s.pad(2)}/{n.upperInitial()} {s.pad(2)}x{es*.pad(2).join('-')} - {t.upperInitial().replacePart(replacement = ', Part $1')}" "animeFormat=J:/Anime/{n.upperInitial()}/{fn}" "movieFormat=J:/Film/{y}/{allOf{info.OriginalName.upperInitial()}{n.upperInitial()}.unique().join(' - ')} {'('+y+')'} {'(Part '+pi+' of '+pn+')'}" "musicFormat=J:/Music (Unsorted)/{artist.upperInitial()}/{'('+y+') '}{album.upperInitial()}/{artist.upperInitial()} - {t.upperInitial()}"

Re: [Error] Processing 3 unsorted files | Illegal parameter: map

Posted: 26 Jan 2017, 15:24
by rednoah
No, label has to be set in the torrent client.

Alternatively you can call your own *.cmd script which then calls the amc script with different ut_label options depending on what value utorrent passes in via the %L variable.

Re: [Error] Processing 3 unsorted files | Illegal parameter: map

Posted: 27 Jan 2017, 00:28
by whereswaller
Hi rednoah,
Can I nest an if/else statement inside the SeriesFormat definition in the amc script? I'm getting the following error "SyntaxError: unexpected token: ?".

I'm keen to perform this task in the one script if possible.

Code: Select all

filebot.launcher.exe -script fn:amc --output "C:/Users/James/Downloads" --log-file amc.log --action copy --conflict skip -non-strict --def music=y subtitles=en artwork=n --def plex=localhost --def pushbullet=XKGdtNocBxdADepDy30ptyWFHrVW6E8I --def clean=y --def unsorted=y "ut_label=%L" "ut_state=%S" "ut_title=%N" "ut_kind=%K" "ut_file=%F" "ut_dir=%D" --def "seriesFormat={n = (?i)Frontline|Air Crash Investigation|Mayday|Horizon|Kourtney And Khloe Take Miami|Kourtney And Khloé Take Miami|Kourtney And Khloe Take The Hamptons|Kourtney And Khloé Take The Hamptons|UFC ? C:\Users\James\Downloads\Unsorted\{fn} : I:/Television/{n.upperInitial()}/{'Season '+s.pad(2)}/{n.upperInitial()} {s.pad(2)}x{es*.pad(2).join('-')} - {t.upperInitial().replacePart(replacement = ', Part $1')}}" "animeFormat=J:/Anime/{n.upperInitial()}/{fn}" "movieFormat=J:/Film/{y}/{allOf{info.OriginalName.upperInitial()}{n.upperInitial()}.unique().join(' - ')} {'('+y+')'} {'(Part '+pi+' of '+pn+')'}" "musicFormat=J:/Music (Unsorted)/{artist.upperInitial()}/{'('+y+') '}{album.upperInitial()}/{artist.upperInitial()} - {t.upperInitial()}"

Re: [Error] Processing 3 unsorted files | Illegal parameter: map

Posted: 27 Jan 2017, 06:38
by rednoah
Your format is wrong, or CMD screws up your format during argument parsing.

1. Use the Format Editor GUI to prototype formats
2. Use @files to pass in formats as raw text instead of using CMD arguments

:idea: Use @file syntax for reading cmdline args from external text files.

Re: [Error] Processing 3 unsorted files | Illegal parameter: map

Posted: 04 Mar 2017, 06:45
by whereswaller
In case anyone is interested in the eventual solution, please see below:

uTorrent script

Code: Select all

filebot.launcher.exe -script fn:amc --output "C:/Users/James/Downloads" --log-file amc.log --action copy --conflict skip -non-strict --def music=y subtitles=en artwork=n --def plex=localhost --def pushbullet=XXXXX --def clean=y --def unsorted=y "ut_label=%L" "ut_state=%S" "ut_title=%N" "ut_kind=%K" "ut_file=%F" "ut_dir=%D" --def @"C:\Program Files\FileBot\amcformats.txt"
amcformats.txt

Code: Select all

seriesFormat={n =~ /Frontline|Air Crash Investigation|Mayday|Horizon|Kourtney and Kim Take Miami|Kourtney and Khloe Take Miami|Kourtney and Khloé Take Miami|Kourtney and Khloe Take the Hamptons|Kourtney and Khloé Take the Hamptons|UFC/ ? 'C:/Users/James/Downloads/Unsorted/'+fn : 'I:/Television/'+n.upperInitial()+'/Season '+s.pad(2)+'/'+n.upperInitial()+' '+s.pad(2)+'x'+es*.pad(2).join('-')+' - '+t.upperInitial().replacePart(replacement = ', Part $1')}
animeFormat=J:/Anime/{n.upperInitial()}/{fn}" "movieFormat=J:/Film/{y}/{allOf{info.OriginalName.upperInitial()}{n.upperInitial()}.unique().join(' - ')} {'('+y+')'} {'(Part '+pi+' of '+pn+')'}
musicFormat=J:/Music (Unsorted)/{artist.upperInitial()}/{'('+y+') '}{album.upperInitial()}/{artist.upperInitial()} - {t.upperInitial()}