Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Harmonize Title-Parsing of Movies and TV-Series #975

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

rcrdnalor
Copy link
Contributor

MythTV parses filenames of movies and series according
the scheme defined in
https://www.mythtv.org/wiki/MythVideo_File_Parsing

For tv-series, it is allowed to add the year in the title,
like The Forsyte Saga (1967) or The Forsyte Saga (2002),
e.g.: The Forsyte Saga (1967) 1x01 A Family Festival.mkv
is correctly parsed.
This may help the television grabber of MythTV to find the
correct entry.

In contrast, all kind of braces are removed from the filename
when parsing video titles:
Ocean's Eleven (2001).mp4 becomes Ocean's Eleven 2001
according the filename convention on the wiki.
This confuses the movie grabber of MythTV because it
cannot be distinguished whether the year is part of the
title or it is the year of the release. For exact this reason,
grabbing for titles ending with a year is not implemented in
the movie grabber tmdb3.py.
Popular examples for different movies with year in the title:
Wonder Woman vs. Wonder Woman 1984
Blues Brothers vs. Blues Brothers 2000

This change respects parentheses "()" in the filename of
a movie, thus parsing of the release year will work.
Furhermore, it enables correct parsing of titles containing
parentheses, like I (Almost) Got away with It or
(T)Raumschiff Surprise - Periode 1.
Advanced searches on imdb.com for 'parenthesis in title'
and 'movies with year in the title' show a lot of matches,
but I found no movie title that ends with a year (4 digits)
in parentheses.

The wiki page at https://www.mythtv.org/wiki/MythVideo_File_Parsing
needs to be upated that the correct syntax is from now on
"A Movie Title (YYYY).mpg" instead of "A Movie Title YYYY.mpg".
The latter was introduced in 2012 without providing a rationale,
but afaik never implemented by the MyhTV movie grabbers
(ttmdb3.py, tmdb.py or its predecessor jamu.py).
Backward compatibility is provided, i.e.: adding a releaase year
without parentheses works the same way as before this change:
The movie grabber will probably not find the correct entry.

This pull reqest supersedes PR #103 .

Checklist

This change respects parentheses, i.e.: curved marks "()"
in the parsed filenames of a movie, thus parsing of the
release year in parentheses will work.
It enables MythTV's movie grabber to extract the release year
from the parsed filename and do a search for title with year.
The correct syntax for a filename is from now on
"A Movie Title (YYYY).mpg" instead of "A Movie Title YYYY.mpg"
as stated in the wiki.
It resolves ambiguous parsing of different movie titles like
`Wonder Woman 1984` and `Wonder Woman`.

Note: For tv-series, it is already allowed to add the year
in the title, like `The Forsyte Saga (1967)`
e.g.: `The Forsyte Saga (1967) 01x01 A Family Festival.mkv`
is correctly parsed.

Fixes MythTV#974
@rcrdnalor rcrdnalor requested a review from jpoet November 21, 2024 19:49
@rcrdnalor
Copy link
Contributor Author

@jpoet : Could you please review this PR? I know from the past conversations on the mailing list, that you are interested in this feature.
Thx, Roland

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant