Page 1 of 1
Error in the suball script
Posted: 06 Jan 2015, 22:49
by doopsuiker
Hi!
Since updating to the latest version, I can't use the "get-missing-subtitles -r" command anymore. When trying to use the suball script instead, I found a bug.
My (very basic) .bat file goes like this:
Code: Select all
filebot "E:\Series" -script fn:suball --lang en -non-strict
It works good for most folders/files, but when there is a folder with media files and also a subfolder with media files, filebot only downloads subtitles for the media files in the folder, not for the media files in the subfolder. This wasn't the case with the old "get-missing-subtitles -r" command.
Could you please help me change the suball script, so it can also download subtitles for media files in the subfolders?
Re: Error in the suball script
Posted: 06 Jan 2015, 23:35
by rednoah
If you can give me all the file paths as text I will have a look at it.
Re: Error in the suball script
Posted: 07 Jan 2015, 00:58
by doopsuiker
I have
with
Code: Select all
"E:\Series\Boardwalk Empire\Boardwalk.Empire.S05E02.720p.HDTV.x264-KILLERS"
and
Code: Select all
"E:\Series\Boardwalk Empire\Boardwalk.Empire.S05E03.720p.HDTV.x264-KILLERS"
as subfolders.
The other files in the "Boardwalk Empire" folder get subtitles, but not in the subfolders
Re: Error in the suball script
Posted: 07 Jan 2015, 01:04
by rednoah
So you have some episode files in the "Boardwalk Empire" folder but also some episode files have their own folders? That's kinda odd and inconsistent. I recommend using a standard {n}/{'Season '+s}/{n} - {s00e00} - {t} structure. Or you can make episode folders for all episodes and that should work as well.
Re: Error in the suball script
Posted: 13 Jan 2015, 16:32
by hharold
Hi,
Since the switch from -get-missing-subtitles to fn:suball all my tvshow path are excluded, and no subtitles seem to get downloaded anymore:
Synology> filebot -script fn:suball /volume1/tvshow/ --lang nl --output srt --encoding utf8 --db opensubtitles -non-strict
Exclude: /volume1/tvshow/Allo Allo/Season 1
Exclude: /volume1/tvshow/Celblok H/Season 2
Exclude: /volume1/tvshow/Criminal Minds/Season 10
Exclude: /volume1/tvshow/CSI Crime Scene Investigation/Season 13
etc, etc,...
most folders contain MKV files of about 1GB, most without subtitles embedded.,
Any ideas ?
cheers,
Harold
Re: Error in the suball script
Posted: 13 Jan 2015, 17:59
by rednoah
Here's the docs:
viewtopic.php?f=4&t=5&p=8871#p8871
A quick look at the (very easy to read) code might help to see which rule causes files to be excluded.
Re: Error in the suball script
Posted: 13 Jan 2015, 20:48
by hharold
I think the reason is that I have installed the portable version on my Synology, which does not include MediaInfo.
Therefor the checks with the getMediaInfo component fail, and it ignores all files.
If I edit the suball.groovy, remove the two getMediaInfo lines and call it locally, the script succeeds.
Cheers,
Harold
Re: Error in the suball script
Posted: 14 Jan 2015, 16:22
by rednoah
Since you seem to be calling the script on your entire structure, and you're probably doing this repeatedly, I highly recommend setting
--def maxAgeDays=7 or risk getting banned.
What version of FileBot are you using? Missing MediaInfo won't cause files to be ignored, that condition just won't work, at the very least if you use the latest via
filebot -script dev:suball 
Re: Error in the suball script
Posted: 19 Jan 2015, 10:27
by hharold
My current version is:
FileBot 4.5.3 (r2729) / Java(TM) SE Embedded Runtime Environment 1.8.0 (headless)
With the 'online' suball script, all folders still appear as Exclude :
filebot -script dev:suball /volume1/tvshow --def maxAgeDays=7 --lang nl --output srt --encoding utf8 --db opensubtitles -non-strict
...
Exclude: /volume1/tvshow/The Blacklist/Season 02
Exclude: /volume1/tvshow/The Game (2014)/Season 1
Exclude: /volume1/tvshow/The Good Wife/Season 4
Exclude: /volume1/tvshow/The Good Wife/Season 5
Exclude: /volume1/tvshow/The Good Wife/Season 6
Exclude: /volume1/tvshow/The Knick/Season 1
Exclude: /volume1/tvshow/True Detective/Season 1
...etc...
Folders are containing episode in .mkv format, mostly > 800MB.
The script part which currently exludes all folder is the part which says "ignore files that are too short" (minLengthMS)
Re: Error in the suball script
Posted: 19 Jan 2015, 10:37
by rednoah
Does it work if you pass --def minLengthMS=0 along?
Re: Error in the suball script
Posted: 19 Jan 2015, 11:44
by hharold
Thanks !
indeed that works, now I am able to successfully execute the 'online' script.
So it does get a false 'LengthMS'
What does this 1000L parameter mean it the suball script?
Cheers Harold
Re: Error in the suball script
Posted: 19 Jan 2015, 13:11
by rednoah
Make sure it's a long so we don't run into int overflow issues
@see
http://stackoverflow.com/a/770017/1514467
Re: Error in the suball script
Posted: 01 Feb 2015, 12:32
by terra17
Hi, since a couple of days I have the same "Exclude" problem with my always-working script ... why ???
this is the script with the above tricks by rednoah
filebot -script dev:suball '/volume1/torrent/SerieTV/' \
-r \
-non-strict \
--lang it \
--def maxAgeDays=7 \
--def minLengthMS=0 \
--log-file '/volume1/torrent/subtitle.log' \
--output srt \
--conflict override
This is the log
Exclude: /volume1/torrent/SerieTV/Fortitude.S01E01.Episode.One.1080p.WEB-DL.AAC2.0.H.264-BS[rarbg]
Exclude: /volume1/torrent/SerieTV/Fortitude.S01E02.Episode.Two.1080p.WEB-DL.AAC2.0.H.264-BS[rarbg]
Done ヾ(@⌒ー⌒@)ノ
Exclude: /volume1/torrent/SerieTV/Fortitude.S01E01.Episode.One.1080p.WEB-DL.AAC2.0.H.264-BS[rarbg]
Exclude: /volume1/torrent/SerieTV/Fortitude.S01E02.Episode.Two.1080p.WEB-DL.AAC2.0.H.264-BS[rarbg]
Done ヾ(@⌒ー⌒@)ノ
Exclude: /volume1/torrent/SerieTV/Fortitude.S01E01.Episode.One.1080p.WEB-DL.AAC2.0.H.264-BS[rarbg]
Exclude: /volume1/torrent/SerieTV/Fortitude.S01E02.Episode.Two.1080p.WEB-DL.AAC2.0.H.264-BS[rarbg]
Done ヾ(@⌒ー⌒@)ノ
Re: Error in the suball script
Posted: 09 Feb 2015, 14:00
by rednoah
If things get excluded then one of the exclude conditions applies. See the script code for details as to what these conditions are exactly.