divijbindlish / parse-torrent-name

Extract media information from a filename
MIT License
215 stars 60 forks source link

Parsing episode names with year numbers in them results in an incorrect release `year` #35

Open Znuff opened 2 years ago

Znuff commented 2 years ago

Examples:

# ./cli.py  "Attack on Titan - S04E21 - From.You,2000.Years.Ago WEBDL-480p"
{
  "episode": 21,
  "quality": "WEB-DL",
  "title": "Attack on Titan",
  "season": 4,
  "encoder": "Years.Ago",
  "year": 2000,
  "resolution": "480p",
  "episodeName": "From You,"
}

# ./cli.py "Heroes - S03E23 - 1961 Bluray-720p"
{
  "episode": 23,
  "quality": "Blu-ray",
  "title": "Heroes",
  "season": 3,
  "year": 1961,
  "resolution": "720p"
}

# ./cli.py "Stargate SG-1 - S02E21 - 1969 HDTV-720p"
{
  "episode": 21,
  "quality": "HDTV",
  "title": "Stargate SG-1",
  "season": 2,
  "year": 1969,
  "resolution": "720p"
}

This obviously creates some issues when I send release year as 1969 for Stargate SG-1, for example :)