Open more-pepsi opened 2 years ago
Hey, I'm unsure what the issue is - the titles you provide parse correctly for me. Could you provide the exact inputs and outputs you are having issues with?
Sons of Anarchy Season 3 Complete 1920 x 1080 x264 Phun Psyz Muhammad.Ali.S01.COMPLETE.720p.WEBRip.x264-GalaxyTV[TGx]
Guess that would be a rule like if complete comes after season token
then the complete token is discarded?
if complete season gets set, while episode is left undefined
>>> PTN.parse('Sons of Anarchy Season 3 Complete 1920 x 1080 x264 Phun Psyz')
{'year': 1920, 'codec': 'x264', 'title': 'Sons of Anarchy Season 3 Complete', 'group': 'Psyz', 'excess': ['x', '1080', 'Phun']}
>>> PTN.parse('Muhammad.Ali.S01.COMPLETE.720p.WEBRip.x264-GalaxyTV[TGx]')
{'resolution': '720p', 'quality': 'WEBRip', 'codec': 'x264', 'title': 'Muhammad Ali S01 COMPLETE', 'group': 'GalaxyTV[TGx]'}
Also its not documented how to import your lib on the home page. For a nooblet like me thats handy ❤️ i'll do the pr if you want
Why is season n
kept also. Is this not meant to work on dirs. In this case, the directory holds most of the info and the file name contains only the episode number. So I need to parse it.
Hey, yes currently it doesn't work on directories - if you want to open a separate issue for this, with some examples, I could take a look. Not high priority atm though.
As for the other examples, I fixed the resolution not being found when there's some extra delimiters.
Currently this is on the dev
branch - it'll be pushed soon to main & PyPI.
Will parse the following out of its respective torrent string into the title property Hitlers Gold S01 COMPLETE []
Sons of Anarchy Season 3 Complete []
Muhammad Ali S01 COMPLETE []
Time 2021 S01 COMPLETE []
Sons Of Anarchy Season 5 - COMPLETE []
Mayans MC Season 1 Complete []
Sorry the [] is my error
But I do't wan the complete and S01 etc