You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Replace vendored musicbrainzngs with wnpmb package
Drop Python 3.10 support; minimum version is now Python 3.11
(required by wnpmb).
**MusicBrainz client overhaul**
Remove the vendored musicbrainzngs library (XML/aiohttp-based),
the custom client.py (~420 lines), and parser.py (~340 lines).
Replace with wnpmb — a JSON/httpx async MusicBrainz client —
installed as a direct package dependency. helper.py rewritten to
use wnpmb's API directly.
**Release and recording selection improvements**
wnpmb's select_best_release scores studio albums over singles/EPs,
so album metadata is now more authoritative. find_recording() now
receives a year hint (extracted via get_best_year(), which prefers
originalyear > date > year) for better disambiguation of same-titled
recordings across eras. artistwebsites moved out of the cached
recording payload (config-dependent, must be computed fresh).
**Discogs URL injection fix**
Restore original gate logic: inject Discogs URL from MB artist
relations when discogs/enabled OR musicbrainz/discogs is set.
Migration had changed this to musicbrainz/discogs only, silently
dropping URLs for users with Discogs enabled.
**apicache event loop fix**
asyncio.Lock is bound to the event loop at creation time. Replace
the singleton lock with a property that recreates it when the
running loop changes, fixing test isolation failures under
per-function asyncio_mode.
**tinytag bpm/key fixes**
M4A stores bpm as a list where the first element may be a base64
float32 blob; scan the list for the first numeric string value.
M4A initial_key (standard musical key) now takes priority over key
(Serato internal code). Both fields unwrap list input correctly.
**New utility**
nowplaying/utils/metadata.py: get_best_year() centralises the
originalyear/date/year precedence logic used across helper.py and
processors.py.
**Tests**
Add unit tests for date normalisation, artist-in-title stripping,
bpm multi-value decoding, and key field priority. Update integration
tests to reflect improved release selection accuracy and correct
multi-artist field handling.
0 commit comments