Skip to content

mam: do not file another book by the same author - #35

Draft
cursor[bot] wants to merge 1 commit into
mainfrom
cursor/critical-bug-management-a8f9
Draft

cursor[bot] wants to merge 1 commit into
mainfrom
cursor/critical-bug-management-a8f9

Conversation

@cursor

@cursor cursor Bot commented Oct 6, 2026

Copy link
Copy Markdown

MAM ranking accepted a different snatched book by the same author when the id3 title and artist were already usable. Search is by filename (01.mp3, file.m4b), and the author-only gate skipped the title check unless the release name had to supply title or authors.

Impact: The Guest tagged as James Patterson was filed as Along Came a Spider (token_sort 67, above matchrate 60). Typical trigger: a multi-file release whose first file is 01.mp3 / file.m4b, metadata includes mam, non-interactive run.

Fix: Require a title match whenever the id3/parsed title is not junk, and apply Config/matchrate the same way _rankAudible already does. Author-only remains only for junk/empty titles.

Validation: ParsedAuthorsMamRankingTest (good id3 reject + accept; existing parsed-author cases). Full suite 223 tests OK. Correctness and security review of the diff: no findings.

Open in Web View Automation 

MAM search is by filename, so a snatched hit for another book by the same
author used to pass the author-only gate whenever the tags did not need
parsing. The Guest tagged as James Patterson was filed as Along Came a
Spider (token_sort 67, above matchrate 60). Ranking now requires a title
match for a non-junk id3/parsed title and applies Config/matchrate.

Co-authored-by: Mancolt <Mancolt@users.noreply.github.com>
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