Why is S11E14 matched as S03E14??

Any questions? Need some help?
Post Reply
mt69298
Posts: 2
Joined: 20 Sep 2012, 09:08

Why is S11E14 matched as S03E14??

Post by mt69298 »

I'm having trouble understanding why Filebot is mismatching names in this case. First is the case when I run the script as "strict".

Code: Select all

java -jar filebot-3.0-r1218-ttfix.jar -script linkrename.groovy /media/Gargant/Downloads/torrent/Grand.Designs.S11E14.WS.PDTV.XviD-C4TV/

Code: Select all

jonas@tvdator:~$ java -jar FileBot.jar -script linkrename.groovy /media/Gargant/Downloads/torrent/Grand.Designs.S11E14.WS.PDTV.XviD-C4TV/
[/media/Gargant/Downloads/torrent/Grand.Designs.S11E14.WS.PDTV.XviD-C4TV]
Linking from /media/Gargant/Downloads/torrent/Grand.Designs.S11E14.WS.PDTV.XviD-C4TV...
TV Show
Rename episodes using [TheTVDB]
Auto-detected query: [grand designs]
Failed to auto-select search result: [Grand Designs, Grand Designs Indoors, Grand Designs Trade Secrets, Grand Designs Live, Grand Designs Abroad, Grand Designs Australia, Grand Designs Today]
Failed to fetch episode data: [grand designs]
Exception: Unable to match files to episode data
Done ヾ(@⌒ー⌒@)ノ
OK, so there are a bunch of shows matching this. Even though the query is an exact match to the first one it fails. Other posts suggest that non-strict is required in this case, presumably to make it auto select the first hit in case of multiple matches (correct me if I'm wrong).

Here's the output when doing it "non-strict" then.

Code: Select all

java -jar filebot-3.0-r1218-ttfix.jar -non-strict -script linkrename.groovy /media/Gargant/Downloads/torrent/Grand.Designs.S11E14.WS.PDTV.XviD-C4TV/

Code: Select all

jonas@tvdator:~$ java -jar FileBot.jar -script linkrename.groovy -non-strict /media/Gargant/Downloads/torrent/Grand.Designs.S11E14.WS.PDTV.XviD-C4TV/
[/media/Gargant/Downloads/torrent/Grand.Designs.S11E14.WS.PDTV.XviD-C4TV]
Linking from /media/Gargant/Downloads/torrent/Grand.Designs.S11E14.WS.PDTV.XviD-C4TV...
^Cjonas@tvdator:~$ java -jar FileBot.jar -script linkrename.groovy -non-strict /media/Gargant/Downloads/torrent/Grand.Designs.S11E14.WS.PDTV.XviD-C4TV/
[/media/Gargant/Downloads/torrent/Grand.Designs.S11E14.WS.PDTV.XviD-C4TV]
Linking from /media/Gargant/Downloads/torrent/Grand.Designs.S11E14.WS.PDTV.XviD-C4TV...
TV Show
Rename episodes using [TheTVDB]
Auto-detected query: [grand designs]
Fetching episode data for [Grand Designs]
Fetching episode data for [Grand Designs Live]
Fetching episode data for [Grand Designs Today]
Fetching episode data for [Grand Designs Abroad]
Fetching episode data for [Grand Designs Indoors]
Fetching episode data for [Grand Designs Australia]
Fetching episode data for [Grand Designs Trade Secrets]
Stripping invalid characters from new path: /media/Gargant/Film/TV-Serier/Grand Designs/Season 3/Grand Designs - S03E14 - Revisited - Cumbria: The Underground House
[HARDLINK] Rename [/media/Gargant/Downloads/torrent/Grand.Designs.S11E14.WS.PDTV.XviD-C4TV/grand.designs.s11e14.avi] to [/media/Gargant/Film/TV-Serier/Grand Designs/Season 3/Grand Designs - S03E14 - Revisited - Cumbria The Underground House.avi]
Processed 1 files
Done ヾ(@⌒ー⌒@)ノ
OK so in this case it does auto select the correct show, but why does it completely bork the episode match here? Why is "S11E14" being matched to "S03E14" ?? There's not even a 3 in the path!

Any assistance would be most welcome. Filebot is really awesome but this issue is confusing me and is preventing total automation when downloads complete.
Here's some other information if that'll help:

Version: 3.0-r1218-ttfix

Contents of linkrename.groovy:

Code: Select all

// Personalized settings and format
def mediaDir = "/media/Gargant/Film/"
def movieDir = mediaDir + "Film"
def tvDir = mediaDir + "TV-Serier"

def tvFormat = "/media/Gargant/Film/TV-Serier/{n}/{episode.special ? 'Special' : 'Season '+s}/{n} - {episode.special ? 'S00E'+special.pad(2) : s00e00} - {t.replacePart(' Part \$1')}"
def movieFormat =  "/media/Gargant/Film/Filmer/{n} ({y})/{fn}"

println args


/*
* Takes the download directory as argument
*/
args.each { 
	println "Linking from $it..."
	
	it.getFiles{ it.isVideo() && !(it.path =~ /\b(?i:sample|trailer|extras|deleted.scenes|music.video|scrapbook)\b/) }.each { 
		def tvs = detectSeriesName(it)
   		def mov = detectMovie(it, false)
		// DECIDE EPISODE VS MOVIE (IF NOT CLEAR)
   		if (tvs && mov) {
      			if (it.name =~ "(?i:$tvs - .+)" || parseEpisodeNumber(it.name) || parseDate(it.name)) {
         			//println "Exclude Movie: $mov"
         			mov = null
      			} else if (detectMovie(it, true)) {
         			//println "Exclude Series: $tvs"
         			tvs = null
      			}
   		}
		
		def fname = null
		if (tvs) {
			println "TV Show"
			fname = rename(file:it, format:tvFormat, db:'TheTVDB', action:'hardlink')
		} else {
			println "Movie"
			fname = rename(file:it, format:movieFormat, db:'TheMovieDB', action:'hardlink')
		}
		if (fname) {
			//println "Getting subtitles..."
			//getMissingSubtitles(file:fname, db:'opensubtitles')
		}
 	}
}
User avatar
rednoah
The Source
Posts: 22923
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: Why is S11E14 matched as S03E14??

Post by rednoah »

According to TheTVDB "Grand Design" Season 11 only lists episodes 1-7. The episode you have doesn't match any online data so that episode falls into the fuzzy logic which completely fails as well since your episode can't exist (according to TheTVDB data). Maybe try TVRage which might order things differently.
:idea: Please read the FAQ and How to Request Help.
mt69298
Posts: 2
Joined: 20 Sep 2012, 09:08

Re: Why is S11E14 matched as S03E14??

Post by mt69298 »

Well that makes sense. Is there any way to auto-select show name but then stop when no good match for the episode is found?

Edit: Changing to TVRage did the trick as they actually sort seasons by air date.
User avatar
rednoah
The Source
Posts: 22923
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: Why is S11E14 matched as S03E14??

Post by rednoah »

Forcing the search query via

Code: Select all

--q "Grand Design"
might do the trick, not sure though. What definitely works is using an episode filter expression via

Code: Select all

--filter "n ==~ /Grand Design/"
:idea: Please read the FAQ and How to Request Help.
Post Reply