Open VeNoMouS opened 5 years ago
You may use special pristine
option to discard default values from a property.
guessit('SS-GB.S01E01.1080p.x265-MeGusta.mkv', {'pristine': ['allowed_countries'], 'allowed_countries': []})
MatchesDict([('title', 'SS-GB'), ('season', 1), ('episode', 1), ('screen_size', '1080p'), ('video_codec', 'H.265'), ('release_group', 'MeGusta'), ('container', 'mkv'), ('mimetype', 'video/x-matroska'), ('type', 'episode')])
Hope it helps.
Sadly it's not documented, but this feature is lying in the code.
ah awesome, yea i was not aware of that option, thanks for the heads up @Toilal
lol, @Toilal im back :)
anythoughts on teh following....
Scorpion.S02E09.US.vs.UN.vs.UK.1080p.WEB-DL.x265.AC3-d3g.mkv
>>> pprint(guessit('Scorpion.S02E09.US.vs.UN.vs.UK.1080p.WEB-DL.x265.AC3-d3g.mkv'))
MatchesDict([('title', 'Scorpion'),
('season', 2),
('episode', 9),
('country', [<Country [US]>, <Country [GB]>]),
('episode_title', 'vs UN vs'),
('screen_size', '1080p'),
('source', 'Web'),
('video_codec', 'H.265'),
('audio_codec', 'Dolby Digital'),
('release_group', 'd3g'),
('container', 'mkv'),
('mimetype', 'video/x-matroska'),
('type', 'episode')])
>>> pprint(guessit('Scorpion.S02E09.US.vs.UN.vs.UK.1080p.WEB-DL.x265.AC3-d3g.mkv', {'pristine': ['allowed_countries'], 'allowed_countries': []}))
MatchesDict([('title', 'Scorpion'),
('season', 2),
('episode', 9),
('episode_title', 'US vs UN vs'),
('language', <Language [uk]>),
('screen_size', '1080p'),
('source', 'Web'),
('video_codec', 'H.265'),
('audio_codec', 'Dolby Digital'),
('release_group', 'd3g'),
('container', 'mkv'),
('mimetype', 'video/x-matroska'),
('type', 'episode')])
I mean... sure I could allowed_languages
hijack... but clearly that is a valid scene release title and all..
pprint(guessit('Scorpion.S02E09.US.vs.UN.vs.UK.1080p.WEB-DL.x265.AC3-d3g.mkv', {'pristine': ['allowed_countries', 'allowed_languages'], 'allowed_countries': [], 'allowed_languages': []}))
MatchesDict([('title', 'Scorpion'),
('season', 2),
('episode', 9),
('episode_title', 'US vs UN vs UK'),
('screen_size', '1080p'),
('source', 'Web'),
('video_codec', 'H.265'),
('audio_codec', 'Dolby Digital'),
('release_group', 'd3g'),
('container', 'mkv'),
('mimetype', 'video/x-matroska'),
('type', 'episode')])
Addtionally ... this thinks the episode_title is the year..
Heroes.S03E23.1961.1080p.BluRay.x265.AC3-d3g.mkv
>>> pprint(guessit('Heroes.S03E23.1961.1080p.BluRay.x265.AC3-d3g.mkv'))
MatchesDict([('title', 'Heroes'),
('season', 3),
('episode', 23),
('year', 1961),
('screen_size', '1080p'),
('source', 'Blu-ray'),
('video_codec', 'H.265'),
('audio_codec', 'Dolby Digital'),
('release_group', 'd3g'),
('container', 'mkv'),
('mimetype', 'video/x-matroska'),
('type', 'episode')])
>>>
I guess I could do {'excludes': ['year', 'country', 'language']}
for both... but not exactly a very clean way...
If you have default of "allowed_countries" in the options.json you cannot overrite the existing list...
This came up with "SS-GB" - #358 , as it was forcing country detection on me even though I had my work around in place from previous ticket.