Skip to content

fix(ftintitle): parenthetical features#6716

Open
treyturner wants to merge 1 commit into
beetbox:masterfrom
treyturner:fix/ftintitle_parenthetical_features
Open

fix(ftintitle): parenthetical features#6716
treyturner wants to merge 1 commit into
beetbox:masterfrom
treyturner:fix/ftintitle_parenthetical_features

Conversation

@treyturner

@treyturner treyturner commented Jun 7, 2026

Copy link
Copy Markdown
Contributor

Description

Fixes #6715: ftintitle handling for featured artists wrapped in parentheses or square brackets.

Before this change, parenthetical features were split at the feature token but the surrounding delimiters were left behind on both sides. For example:

Alice (ft. Bob) - Song

became:

Alice ( - Song ft. Bob)

With this PR, we get the intended:

Alice - Song ft. Bob

The same cleanup applies to square brackets, e.g. Alice [ft. Bob].

Details

  • Strip a matching () or [] pair when it encloses the feature marker split.
  • Ensures artist names with parens or brackets retain them, e.g. Alice ft. (Bob) still extracts (Bob).
  • Handle album-artist matching when the album artist is the bracketed featured artist, e.g. Alice [ft. Bob] on Bob’s album extracts Alice.
  • Doc update explaining the behavior.

Tests

  • Added focused ftintitle cases for:
    • functional parenthetical feature cleanup
    • bracketed find_feat_part album-artist behavior
    • split_on_feat delimiter cleanup and non-cleanup boundaries

To Do

  • Documentation. (If you've added a new command-line flag, for example, find the appropriate page under docs/ to describe it.)
  • Changelog. (Add an entry to docs/changelog.rst to the bottom of one of the lists near the top of the document.)
  • Tests. (Very much encouraged but not strictly required.)

@treyturner treyturner requested a review from a team as a code owner June 7, 2026 08:36
@github-actions github-actions Bot added the ftintitle ftintitle plugin label Jun 7, 2026
@github-actions

github-actions Bot commented Jun 7, 2026

Copy link
Copy Markdown

Thank you for the PR! The changelog has not been updated, so here is a friendly reminder to check if you need to add an entry.

@codecov

codecov Bot commented Jun 7, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 74.53%. Comparing base (beff630) to head (0806299).
✅ All tests successful. No failed tests found.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #6716      +/-   ##
==========================================
- Coverage   74.54%   74.53%   -0.01%     
==========================================
  Files         162      162              
  Lines       20832    20842      +10     
  Branches     3298     3300       +2     
==========================================
+ Hits        15529    15535       +6     
- Misses       4548     4550       +2     
- Partials      755      757       +2     
Files with missing lines Coverage Δ
beetsplug/ftintitle.py 90.22% <100.00%> (-0.84%) ⬇️

... and 1 file with indirect coverage changes

🚀 New features to boost your workflow:
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@treyturner treyturner force-pushed the fix/ftintitle_parenthetical_features branch 5 times, most recently from 8b03a62 to f90d80b Compare June 11, 2026 21:55
Comment thread beetsplug/ftintitle.py Outdated
@treyturner treyturner force-pushed the fix/ftintitle_parenthetical_features branch from f90d80b to 283c916 Compare June 14, 2026 03:50
@treyturner treyturner force-pushed the fix/ftintitle_parenthetical_features branch from 283c916 to 0806299 Compare June 14, 2026 03:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ftintitle ftintitle plugin

Projects

None yet

Development

Successfully merging this pull request may close these issues.

ftintitle: parenthetical features are broken

2 participants