Repository navigation
mam: do not file a sequel whose subtitle contains the series name - #41
Draft
cursor[bot] wants to merge 1 commit into
Draft
cursor[bot] wants to merge 1 commit into
cursor[bot] wants to merge 1 commit into
Conversation
sameMamTitle treated a MAM-only subtitle as the row's series name when token_set_ratio was high, which is 100 if the series name is only a subset. Dune then matched Dune: Children of Dune (series Dune), so accept_unsnatched could file book 1 as a later cycle volume. Use token_sort_ratio, the same bar as the main title. Leviathan Wakes: The Expanse, Book 1 still matches series The Expanse. Co-authored-by: Mancolt <Mancolt@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Bug and impact
With
mam/accept_unsnatchedon,sameMamTitletreated a MAM-only subtitle as the row's series name whenevertoken_set_ratiowas high. That score is 100 when the series name is only a subset of the subtitle, so Dune matched Dune: Children of Dune and Dune: Dune Messiah (series Dune).MAM's file-name search also looks in title and author, so a search for
Dune.m4breturns later cycle books. If the release's own torrent failed the exact author check (MAM listedHerbert, Frank) the sequel was the only passing row and book 1 was filed as a later volume.This is separate from #40 (
samePositionignoring series parts when titles omitBook N). #40 still accepts the sequel when the id3 tags have no part.Root cause
The documented rule is that a subtitle only MAM has must be the candidate's own series name (
Leviathan Wakes: The Expanse, Book 1). The implementation usedtoken_set_ratio, which ignores extra subtitle words.Fix
Use
token_sort_ratiowith the same 90 bar as the main title. Leviathan Wakes: The Expanse, Book 1 still matches (Book N is stripped first). Dune: Children of Dune / Dune: Dune Messiah / Foundation: Foundation and Empire are refused.Validation
GateTest.test_a_sequel_whose_subtitle_contains_the_series_name_is_not_accepted: own torrentHerbert, Frank+ Children of Dune is not used.test_sibling_volumes_parts_and_box_sets_are_not_the_same_titlefor Dune / Messiah / Foundation; Leviathan Wakes still accepted.