Page 1 of 1

removeTrailingBrackets exception with non english language

Posted: 11 May 2016, 21:42
by Lukeid
Hello,

I'm having a rename problem since I upgraded Filebot 4.7 (r3894) -> 4.7 (r3935).

When I try to rename this episode I get an exception:

Code: Select all

filebot -rename "Hawaii Five 0/Hawaii Five 0 - 6x19.avi" --db TheTVDB --lang es --q "Hawaii Five 0" --format "/MySeries/{n}/T{s}/{n} {sxe} - {t}" --encoding utf8 -non-strict
Rename episodes using [TheTVDB]
Fetching episode data for [Hawaii Five-0]
Fetching episode data for [Hawaii Five-O]
null
java.lang.NullPointerException
	at net.filebot.similarity.Normalization.removeTrailingBrackets(Normalization.java:75)
	at net.filebot.similarity.EpisodeMetrics$5$$Lambda$129/27517546.apply(Unknown Source)
	at one.util.streamex.TailConcatSpliterator.tryAdvance(TailConcatSpliterator.java:48)
	at one.util.streamex.AbstractStreamEx.toArray(AbstractStreamEx.java:378)
	at one.util.streamex.StreamEx.toArray(StreamEx.java:79)
	at one.util.streamex.AbstractStreamEx.toArray(AbstractStreamEx.java:371)
	at one.util.streamex.StreamEx.toArray(StreamEx.java:79)
	at net.filebot.similarity.EpisodeMetrics$5.fields(EpisodeMetrics.java:203)
	at net.filebot.similarity.EpisodeMetrics$5.getSimilarity(EpisodeMetrics.java:180)
	at net.filebot.similarity.EpisodeMetrics.getSimilarity(EpisodeMetrics.java:665)
	at net.filebot.similarity.Matcher.mapBySimilarity(Matcher.java:140)
	at net.filebot.similarity.Matcher.deepMatch(Matcher.java:107)
	at net.filebot.similarity.EpisodeMatcher.deepMatch(EpisodeMatcher.java:82)
	at net.filebot.similarity.Matcher.deepMatch(Matcher.java:123)
	at net.filebot.similarity.EpisodeMatcher.deepMatch(EpisodeMatcher.java:82)
	at net.filebot.similarity.Matcher.deepMatch(Matcher.java:123)
	at net.filebot.similarity.EpisodeMatcher.deepMatch(EpisodeMatcher.java:82)
	at net.filebot.similarity.Matcher.deepMatch(Matcher.java:123)
	at net.filebot.similarity.EpisodeMatcher.deepMatch(EpisodeMatcher.java:82)
	at net.filebot.similarity.Matcher.deepMatch(Matcher.java:123)
	at net.filebot.similarity.EpisodeMatcher.deepMatch(EpisodeMatcher.java:82)
	at net.filebot.similarity.Matcher.match(Matcher.java:54)
	at net.filebot.cli.CmdlineOperations.matchEpisodes(CmdlineOperations.java:261)
	at net.filebot.cli.CmdlineOperations.renameSeries(CmdlineOperations.java:217)
	at net.filebot.cli.CmdlineOperations.rename(CmdlineOperations.java:110)
	at net.filebot.cli.ArgumentProcessor.runCommand(ArgumentProcessor.java:90)
	at net.filebot.cli.ArgumentProcessor.run(ArgumentProcessor.java:26)
	at net.filebot.Main.main(Main.java:120)
Failure (°_°)
I tried a lot of things and nothing worked but changing language to "--lang en". Once I did that Filebot renamed the episode correctly.
Then I revert the renaming manually and tried again with "--lang es" and that time it worked. :shock:

Maybe Filebot needs to set something internally with english language...

Anyway now it works for my but it is a strange thing that may happen to others.

Best regards,
Lukeid

Re: removeTrailingBrackets exception with non english langua

Posted: 12 May 2016, 15:55
by rednoah
Fixed.

Re: removeTrailingBrackets exception with non english langua

Posted: 22 May 2016, 18:35
by Lukeid
Verified with r3995. Now it works.

Thank you very much. :)

Re: removeTrailingBrackets exception with non english langua

Posted: 24 May 2016, 22:15
by Lukeid
Hello again,

I didn't notice it till now, but is it possible that now with the new fix episode title appear empty?

For example, if I use Windows graphical version (FileBot 4.7 (r3923)) the tv show name is in spanish and the episode title is sometimes in spanish and sometimes english (I guess that depends if it is available). But in newer linux version (r3995) using command line sometimes episode title is in spanish and sometimes it is empty. Remember that I use the "--lang es" option.

So it seems that something has changed. I would like old version behaviour: if spanish name exist use it and if not use default (english) one. I prefer english title to no title. ;)
Is it possible to have that behaviour with newer versions?

Thank you very much in advance.
Lukeid

Re: removeTrailingBrackets exception with non english langua

Posted: 25 May 2016, 06:26
by rednoah
The new TheTVDB API doesn't support that yet.

You can follow the issue here:
https://trello.com/c/dyEhtfky/16-handle ... age-header