Commit graph

11864 commits

Author SHA1 Message Date
Alok Saboo
4dd165495f Update embedart.py 2023-03-18 19:00:28 -04:00
Alok Saboo
feeeb4080c Update embedart.py 2023-03-18 18:58:32 -04:00
Alok Saboo
f051d67947 Add option to import using URL 2023-03-18 18:23:53 -04:00
Alok Saboo
9f4b43c540 Point to latest docs 2023-03-18 10:56:16 -04:00
Alok Saboo
6d0e5ba8ca Change to GitHub 2023-03-17 11:06:46 -04:00
Alok Saboo
5f87371229 rephrase 2023-03-14 20:57:34 -04:00
Alok Saboo
05cdecfb7c Add more examples to convert plugin 2023-03-14 20:39:47 -04:00
Alok Saboo
53911c74dd Link to dev docs 2023-03-13 11:33:45 -04:00
Alok Saboo
36daf93828 Add instructions to install directly from Github. 2023-03-12 16:28:29 -04:00
J0J0 T
c2c617594f Save Discogs Release ID via MusicBrainz
- Enable fetching 'url-rels' from the MusicBrainz release endpoint.
- A MusicBrainz release might contain a link to a Discogs release
  which we save to the discogs_albumid attribute of the info object.
- For extraction of the release ID from the Discogs URL, we use the method
  provided in the id_extractors util module.
2023-03-12 12:03:31 +01:00
Adrian Sampson
2e18f84b38
Merge pull request #4698 from ghbrown/discogs_client_check
discogs_client version check
2023-03-10 21:56:48 -08:00
ghbrown
f1b7832d52 Change minimum discogs_client version to 2.3.15 2023-03-10 15:28:29 -06:00
J0J0 Todos
9bc6066517
Merge pull request #4699 from arogl/patch-2
Fix typo in beetsplug/deezer.py
2023-03-10 08:34:55 +01:00
Andrew Rogl
e33369d231
Fix typo in beetsplug/deezer.py
Found another typo
2023-03-10 17:28:52 +10:00
ghbrown
bad541e2c4 Address lint errors for discogs_client version check 2023-03-09 17:38:47 -06:00
ghbrown
566a58c8bb Edit changelog for discogs_client version check 2023-03-09 17:23:42 -06:00
ghbrown
437f6e76e4 Add warning about (python3-)discogs-client version 2023-03-09 17:16:11 -06:00
J0J0 Todos
8ec9f5a09b
Merge pull request #4696 from arogl/patch-1
Fix typo in deezer.py
2023-03-09 13:16:24 +01:00
Andrew Rogl
5662fef842
Fix type in deezer.py 2023-03-09 17:05:03 +10:00
J0J0 Todos
40d27f5522
Merge pull request #4633 from JOJ0/refactor_id_extraction
Refactor metadata source ID extraction utilities
2023-03-08 18:46:33 +01:00
J0J0 Todos
c6746ed399 Add a test for Beatport ID extraction 2023-03-08 18:29:04 +01:00
J0J0 Todos
af600497ee Add a test for Deezer ID extraction 2023-03-08 18:28:41 +01:00
J0J0 Todos
c1299f64a1 Add a test for Spotify metadata ID extraction 2023-03-08 18:22:54 +01:00
J0J0 Todos
c48fa0a830 Fix Discogs ID extractor to support short format
- Often discogs release links used to be written as discogs.com/release/<id>
- Extend one of the existing regex patterns to support that by making the
  trailing dash (-) optional.
- Save a new test regex on regex101.com and update the link to it.
2023-03-08 18:12:31 +01:00
J0J0 Todos
aaa4cfce49 Leave note about Bandcamp IDs in id_extractors module. 2023-03-08 18:12:31 +01:00
J0J0 Todos
f36c55f730 Refactor Beatport plugin to use _get_id
from MetadataSourcePlugin and save beatport_id_regex in id_extractors module.
This streamlines the Beatport release ID extraction magic with plugins Deezer
and Spotify.
2023-03-08 18:12:31 +01:00
J0J0 Todos
8ab25694a5 Move Deezer ID regex to id_extractors module
in beets.util package.
2023-03-08 18:12:31 +01:00
J0J0 Todos
284180ec75 Refactor MetadataSourcePlugin._get_id()
and put to use in Spotify plugin.

- Make _get_id() a staticmethod usable from outside a metadata source plugin.
- id_regex now has to be passed as an argument instead of assuming it is
  accessible via an instance variable (self.id_regex).
- In the Spotify plugin, import spotify_id_regex from util.id_extractors
2023-03-08 18:12:31 +01:00
J0J0 Todos
0175a9aed8 Introduce new module beets.util.id_extractors
- We introduce a new submodule of beets.util named id_extractors.
- Parts of the ID extraction utilites required by metadata source plugins
  should live there.
- Also this enables future usage of those utilities from the "outside" of
  metadata source plugins.
- Move Discogs ID extractor to the new module and change test_discogs to use
  the new location.
- Add spotify_id_regex variable to the new module.
2023-03-08 18:12:31 +01:00
J0J0 Todos
8bbaefbdc9
Merge pull request #4643 from Steffo99/sphinx-deps 2023-03-08 16:58:48 +01:00
Stefano Pigozzi
87c43a0b88
Merge remote-tracking branch 'upstream/master' into sphinx-deps 2023-03-08 13:43:22 +00:00
J0J0 Todos
1f9113af73
Merge pull request #4582 from jpluscplusm/jcm_fix_albumtypes
Store `albumtypes` multi-value field consistently in-DB & in-tag, preventing continual file re-tagging
2023-03-08 14:26:19 +01:00
J0J0 Todos
74ac6c4cdc
Merge pull request #4694 from arsaboo/add_plexsync
Add plexsync plugin
2023-03-08 13:32:25 +01:00
Alok Saboo
033f63ad47 Add Github link 2023-03-07 17:18:15 -05:00
Alok Saboo
4c62673e41 Update index.rst 2023-03-07 17:12:11 -05:00
Adrian Sampson
d63bebb113
Merge pull request #4690 from JOJ0/changelog_note_ordering
Improve "Changelog goes here note" in changelog.rst
2023-03-05 18:52:58 -08:00
J0J0 Todos
6336fef1e8 Improve "Changelog goes here note" in changelog.rst 2023-03-04 19:52:03 +01:00
Adrian Sampson
650f710943
Merge pull request #4686 from arsaboo/spotify_fix
Fix Spotify error - added exception for TypeError [small PR]
2023-03-02 19:27:23 -08:00
Alok Saboo
823599f2b4 Update changelog 2023-02-28 18:18:42 -05:00
Alok Saboo
abf6b1e1f3 Update spotify.py 2023-02-28 09:38:23 -05:00
Alok Saboo
c73ecb89d3 Update spotify.py 2023-02-28 09:36:16 -05:00
J0J0 Todos
4908e1ae09 Fix flake8 issues in test_ui.py
that were introduced in 27218a94.
2023-02-28 09:24:30 +01:00
J0J0 Todos
78853cc9c2 Add note to albumtypes plugin docs about #4528
Add a note to the docs of the albumtypes plugin warning about issue #4528 and
linking to the manual fixing description.
2023-02-28 08:53:21 +01:00
J0J0 Todos
7be1eec762 Rewrite changelog entry for #4583
and include linking to manual fixing tutorial.
2023-02-28 08:51:58 +01:00
J0J0 Todos
93fa19f493 Fix albumtypes plugin and its tests
The new database type DelimitedString does list to string and vice versa
conversions itself.
2023-02-27 13:43:03 +01:00
Jonathan Matthews
27218a9490 Mark albumtype/s expected test failure as fixed 2023-02-27 13:43:03 +01:00
J0J0 Todos
cd52a05d3a Add fix for #4528 to changelog 2023-02-27 13:42:45 +01:00
Jonathan Matthews
7cfc39ea27 Realign with known-working code after review by @mkhl
@mkhl was kind enough to do a drive-by review of my proposed changes,
which I'll include here as the GitHub URI may bit-rot over time (it's
technically
[here](bc21caa0d5),
but that commit isn't part of the `beets` repo, so may get GC'd).

I've encorporated all their proposed changes, as their code is being run
against an existing Beets library, whereas my changes were made as I
tried to set up Beets for the first time - thus I'm inclined to trust
their known-working code more than my own!

This is a review starting at
bc21caa0d5 (diff-d53f73df7f26990645e7bdac865ef86a52b67bafc6fe6ad69890b510a57e2955R210)
(`class DelimeteredString(String):`)

> for context this is the version i'm using now:
>
> ```python
> class DelimitedString(String):
>     model_type = list
>
>     def __init__(self, delimiter):
>         self.delimiter = delimiter
>
>     def format(self, value):
>         return self.delimiter.join(value)
>
>     def parse(self, string):
>         if not string:
>             return []
>         return string.split(self.delimiter)
>
>     def to_sql(self, model_value):
>         return self.delimiter.join(model_value)
> ```
>
> i think 'delimited string' is the correct term here
>
> the rest of the code doesn't seem to use many abbreviations, so calling the property `delimiter` seems appropriate
>
> i don't think a default value for the delimiter makes a lot of sense?
>
> the list comprehension and string conversions in `to_sql` don't seem necessary to me, see above. did you run into trouble without them?
>
> the `from_sql` seems to just be missing functionality from the `Type` parent and seems completely unnecessary
>
> `parse` shouldn't be able to fail because at that point, we've ensured that its argument is actually a string. i also added a `if not string` condition because otherwise the empty list of album types would turn into the list containing the empty string (because that's what split returns)
>
> if we don't define a `format` method here we print the internal python representation of the values (i.e. `['album', 'live']` or somesuch) in the `beet write` output. joining on the delimiter nicely formats the output :)
>
> just so i don't ping you twice unnecessarily, i think it's better to instantiate this type with `'; '` (semicolon space) as the delimiter, because that's what was used before to join the albumtypes and what we'll find in the database

All these changes have been made, including the switch from `;` to
`;<space>` as the in-DB separator.
2023-02-27 13:28:29 +01:00
Jonathan Matthews
af65c6d707 Serialise albumtypes field as a semicolon-based DelimeteredString 2023-02-27 13:28:29 +01:00
Jonathan Matthews
41f9ecc73b Introduce new DB type: DelimeteredString 2023-02-27 13:28:29 +01:00