Commit Graph

532 Commits

Author SHA1 Message Date
Sebastian Mohr
7df2789cfd Fixed metadatasource tests. 2026-04-11 11:42:30 +02:00
Sebastian Mohr
8637f138df Fixed some typing issues with rebase 2026-04-11 11:20:31 +02:00
Sebastian Mohr
25255816fa Fixed issue with mpdstats test and removed unregister_all function
as it introduces issues.
2026-04-11 11:05:03 +02:00
Sebastian Mohr
d62bd277fc Renamed PluginTestCasePytest to PluginTest 2026-04-11 11:04:49 +02:00
J0J0 Todos
e0b757ceb3 Remove unused import in lastgenre tests 2026-04-11 02:39:50 +02:00
Šarūnas Nejus
19353999ae Simplify fetch_genre 2026-04-11 02:25:02 +02:00
Šarūnas Nejus
f66cc3fb57 lastgenre: use a single fetch method
Delegate the responsibility of getting relevant model fields to the
client by declaring the genre fetching spec on the class.
2026-04-11 02:25:02 +02:00
Šarūnas Nejus
2ff7887725 Apply all matching rules to a field 2026-04-10 14:54:57 +01:00
Šarūnas Nejus
c9064012a1 Show that only the first pattern applied currently 2026-04-10 11:52:15 +01:00
Šarūnas Nejus
c81cfebc7b Handle list fields in rewrite 2026-04-10 10:43:25 +01:00
Šarūnas Nejus
bfd20b2abc Add a failing test for list fields 2026-04-10 10:37:36 +01:00
Šarūnas Nejus
9b6b7d3cd6 Add tests for rewrite plugin 2026-04-10 09:34:55 +01:00
J0J0 Todos
43e13dcfd3 lastgenre: Tests for genre ignorelist feature 2026-04-09 21:50:29 +02:00
Maxr1998
ee1a1632a0 Fix tests 2026-04-09 10:40:59 +02:00
Mathilde Gilles
e49398b2f5 Merge branch 'master' into fetchart-webp 2026-04-08 16:38:02 +02:00
Alok Saboo
cb8d3abe8d listenbrainz: add --max option and drop per-listen MB lookups
- Add `beet lbimport --max=N` to cap the number of listens fetched.
- Remove the MusicBrainz API lookup from get_tracks_from_listens.
  Previously, every listen without a recording_mbid in the API mapping
  triggered a live MB search, causing the import to hang for hours on
  large listen histories. Matching falls back to artist/title/album
  which is already handled by update_play_counts.
2026-04-08 08:34:48 -04:00
ShimmerGlass
3194666610 feat(fetchart): add support for webp files 2026-04-08 12:39:58 +02:00
Alok Saboo
af8d716b82 address reviewer comments 2026-04-07 20:37:15 -04:00
Alok Saboo
0fe518245e lint 2026-04-07 20:36:36 -04:00
Alok Saboo
9e02536bee ListenBrainz: aggregate play counts and improve pagination logic 2026-04-07 20:31:14 -04:00
ShimmerGlass
142e946588 fix(fetchart): sources definition
The fetchart plugin would silently drop unknown sources defined in
config, leading to hard to debug problems.
The plugin now errors when an unknown source is configured, or when no
sources are configured.
In addition, a single string is now a valid value for `sources` to
either enable all sources with an `*` or a single source.

Fixes: #6336
2026-04-07 18:55:53 +02:00
Šarūnas Nejus
597d5c162a discogs: swap style and genre 2026-04-06 16:40:33 +01:00
ShimmerGlass
f1a95bed57 fix(replaygain): clear conflicting tags on write
There are two ways to store replay gain data on music files: RG_ and
R128_ (opus). before this change the beets replaygain plugin simply set
the right tag based on file format and r128 config value.
there are case, however, when for example an opus files comes with RG_
tags already set. After beet write its replaingain tags the files will
contain both RG_ and R128_ tags with possibly conflicting values.
For example, Navidrome currently always prefers RG_ tags over R128_
regardless of format, leading tags set by beets to be ignored.
23f3556371/model/metadata/map_mediafile.go (L111)

As per RFC 7845: Ogg Encapsulation for the Opus Audio Codec
https://datatracker.ietf.org/doc/html/rfc7845#section-5.2.1
> To avoid confusion with multiple normalization schemes, an Opus
> comment header SHOULD NOT contain any of the REPLAYGAIN_TRACK_GAIN,
> REPLAYGAIN_TRACK_PEAK, REPLAYGAIN_ALBUM_GAIN, or
> REPLAYGAIN_ALBUM_PEAK tags, unless they are only to be used in some
> context where there is guaranteed to be no such confusion.

Since the replaygain plugin does not support setting both RG_ and R128_
at the same time it doesn't make much sense to keep conflicting tags
when writing. These tags are also easy to recalculate if needed either
with beets itself (with a different configuration), or by running
replaygain commands by hand. no valuable information is lost.

This change makes it so the replagain plugin now deletes conflicting
tags when processing library items:
* RG_ are deleted if we set R128_
* R128_ are deleted if we set RG_
2026-04-05 15:19:39 +02:00
Šarūnas Nejus
a867b961cc Migrate arranger -> arrangers 2026-04-05 09:15:23 +01:00
Šarūnas Nejus
85eaa447f0 Migrate composer -> composers 2026-04-05 09:15:23 +01:00
Šarūnas Nejus
c8360e5b11 Use __setattr__ to handle setting legacy string fields 2026-04-05 09:15:23 +01:00
ShimmerGlass
1242f42b37 feat(chroma): add chromasearch command
This command lets user search the database by chromaprint fingerprint
similarity.
Database item fingerprints are computed on the fly if needed.
This is useful for example to check if an unknown / untagged audio file
already exists in the database.
2026-04-04 15:03:42 +02:00
J0J0 Todos
b32f220523 smartplaylist: Test new shell quoting behavior 2026-04-04 13:35:22 +01:00
J0J0 Todos
63b23e4a5c autobpm: Test force, quiet, overwrite fallback 2026-04-03 11:28:37 +02:00
Šarūnas Nejus
db7c753ebe Update listenbrainz accordingly 2026-03-31 01:36:08 +01:00
Šarūnas Nejus
d7c9e268f9 Refactor process_tracks and add tests 2026-03-31 01:36:08 +01:00
zqmfb
60d7953f99 Add test for lastgenre with existing semicolon-delimited tags 2026-03-29 08:39:45 +01:00
Šarūnas Nejus
b8def07121 autotag: use explicit imports 2026-03-28 12:26:27 +00:00
Šarūnas Nejus
5fad834ad2 Ensure we use Distance to initialise Match objects 2026-03-22 19:23:53 +00:00
Šarūnas Nejus
79787cfd97 tagging: fix list albumartists field 2026-03-22 19:23:52 +00:00
kelamg
989fc665c9 Improve test 2026-03-22 01:46:50 +00:00
kelamg
2e70472748 Remove + chars 2026-03-22 01:46:50 +00:00
kelamg
2f83c0869e Fix integration test 2026-03-22 01:46:50 +00:00
kelamg
b3bcb78349 Fix indentation 2026-03-22 01:46:50 +00:00
jochem
55b6fbe77d copied more generic implementation from snejus, and updated the tests and docs accordingly 2026-03-22 01:46:50 +00:00
kelamg
9a735df125 Fix formatting 2026-03-22 01:46:50 +00:00
kelamg
ec4def9e91 Refactor exclusion tests to pytest 2026-03-22 01:46:50 +00:00
jochem
2f9ee89b2a Added feature to exclude albums/songs during importing when auto is enabled, as requested in issue #3523. Also added corresponding tests and documentation. 2026-03-22 01:46:50 +00:00
J0J0 Todos
af8cbc179c lastgenre: Adapt test to canon helpers move 2026-03-17 06:52:30 +01:00
J0J0 Todos
ffc6f23407 lastgenre: Adapt test to last.fm client separation 2026-03-17 06:52:30 +01:00
Andrejs Mivreniks
f9f4af874b feat(play): Add -R/--randomize option to play plugin 2026-03-16 20:33:23 +02:00
Brock Grassy
d21470042a Address comments 2026-03-16 06:52:35 +00:00
Brock Grassy
e36c09d69d Fix lint 2026-03-16 06:52:35 +00:00
Brock Grassy
2c60c3eb49 Address comments and add new test case 2026-03-16 06:52:35 +00:00
Brock Grassy
c51f68be15 Fix rebase in tests 2026-03-16 06:52:35 +00:00