Match: update state for displaced Apple tracks #39
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Context
Independent review of the SPEC reconciliation found that moving a beets item from Apple track A to Apple track B updates B to
matchedbut can leave A persisted asmatchedafter its last association is removed. That violates the state invariant inSPEC.md§7 and causes incorrectlist-tracksoutput.Task
When explicit or interactive matching reassigns an item already associated with another retained Apple track, reconcile the displaced track from its remaining beets associations and mark the selected track
matched. Preserve a displaced permanent skip, and do not fail when the displaced Apple ID has no plugin-state row.Acceptance criteria
unmatched.matched; multiple remaining associations produceambiguous.skipped.matchedand owns the beets association.Completed in
coop/beets-appleplaylistsby implementation commitcc124c9, merged through PR #41 ase4fbbffd4a0bf744d4967c6bfb03e4ffe369869a.Explicit and interactive matching now reconcile the displaced track from its remaining association count, preserve displaced permanent skips, tolerate absent historical state rows, and set the selected track to
matched.Validation: 104 tests passed with warnings promoted to errors, plus Ruff lint, compileall, isolated CLI help, package build, and
git diff --check.