Commit graph

71 commits

Author SHA1 Message Date
Šarūnas Nejus
b3d434f58f
Delegate attribute access to logging 2025-08-30 23:10:21 +01:00
Šarūnas Nejus
1c16b2b308
Replace string concatenation (' + ')
- Join hardcoded strings
- Replace concatenated variables with f-strings
2025-08-30 23:10:15 +01:00
Šarūnas Nejus
7cada1c9f8
Remove no-op decargs 2025-07-08 11:37:33 +01:00
Šarūnas Nejus
c490ac5810
Fix formatting 2025-05-07 10:41:01 +01:00
Šarūnas Nejus
85a17ee503
Reformat the codebase 2024-09-21 11:57:48 +01:00
Lev Gorodetskiy
2a4cf0d335
Codestyle 2024-05-26 11:57:24 -03:00
Lev Gorodetskiy
2130404217
Add timeout to all requests calls 2024-05-25 12:24:53 -03:00
Serene-Arc
a6e5201ff3 Apply formatting tools to all files
This is 'the big one', which touches every file so that it all conforms
to the given standard.
2023-10-22 09:53:18 +10:00
Adrian Sampson
7f7db33cf8
Adapt to some recent flake8/pycodestyle changes
As surfaced in this CI run:
https://github.com/beetbox/beets/actions/runs/5716141601/job/15486984755?pr=4866

These all look like perfectly reasonable improvements that are unlikely
to break anything.
2023-07-31 10:00:41 -07:00
Mark Trolley
55255b0087
Deprecate absubmit and update acousticbrainz plugins
Fixes #4627.

AcousticBrainz is shutting down as of early 2023. Deprecate the absubmit
plugin and update the acousticbrainz plugin to require configuration of
an AcousticBrainz server instance.
2023-02-20 17:42:07 -05:00
Adrian Sampson
c5e68f5643
Adapt to pycodestyle changes 2022-07-30 19:54:24 -04:00
Mark Trolley
bfe008ed24
Fix typo in Acousticbrainz warning log
Add missing space in Acousticbrainz plugin warning log.
2022-06-30 14:19:58 -04:00
Andrew Rogl
ee4268dabb Remove unused imports
Fix imports
Fix formatting
2021-08-26 20:59:48 +10:00
Andrew Rogl
1ec87a3bdd pyupgrade beetsplug and tests
All tests working
More tidy up to be done
2021-08-26 19:12:51 +10:00
Paul Malcolm
5f9a394ca9 Issue #2860 Fetch more acousticbrainz fields 2019-07-23 20:25:26 -04:00
Rainer Hihn
62c1d37bcc Formatting 2019-04-27 17:58:48 +02:00
Rainer Hihn
941dd6e48f Formatting 2019-04-27 17:58:26 +02:00
Rainer Hihn
36dc105dc9 undid quotes in log messages 2019-04-27 17:57:48 +02:00
Rainer Hihn
55fe077e54 Removed PaddedFloat in favour of adding a constructor parameter 2019-04-24 20:39:05 +02:00
Rainer Hihn
07b617b307 Converted all float types to PaddedFloat 2019-04-24 19:55:44 +02:00
Rainer Hihn
7676d2ae5a PaddingInt -> PaddingFloat 2019-04-24 19:54:12 +02:00
Rainer Hihn
3f3b102885 added PaddingFloat 2019-04-24 19:53:01 +02:00
Rainer Hihn
76e333c054 Added item_types 2019-04-23 19:20:55 +02:00
Rainer Hihn
a60935ed1c Prevent scientific notation 2019-04-22 19:50:11 +02:00
Owen Parry
1f45ea00f4 use as_str_seq and fix line length 2017-12-02 11:31:31 -08:00
Owen Parry
eaa84178f7 split long line 2017-11-27 09:11:53 -08:00
Owen Parry
325ae6f0ee Add tags configuration to acousticbrainz plugin 2017-11-27 07:55:38 -08:00
Adrian Sampson
a414872430 Fix a missing parameter (#2349) 2016-12-28 13:36:19 -05:00
Adrian Sampson
8a62087376 Documentation tweaks for #2349 2016-12-28 12:03:57 -05:00
Adrian Sampson
2a3f3d9bfa acousticbrainz: Make some strings into comments
When not in the docstring position, it's better to use "real" comments instead
of string literals.
2016-12-28 12:01:08 -05:00
Adrian Sampson
c27879edbc Slight code formatting tweaks for #2349 2016-12-28 11:59:14 -05:00
Susanna Maria Hepp
7e1e31bddd E128: continuation line under-indented for visual indent? 2016-12-28 15:30:57 +01:00
Susanna Maria Hepp
165f2e189e Repair findings from Travis CI 2016-12-28 15:11:03 +01:00
Susanna Maria Hepp
00371de0bb Changes suggested by @sampsyo 2016-12-27 21:56:39 +01:00
Susanna Maria Hepp
c632949b64 Changes suggested by @Kraymer 2016-12-27 21:48:06 +01:00
Susanna Maria Hepp
bbaad2f17d Introduce force option in acousticbrainz 2016-12-27 13:22:16 +01:00
Susanna Maria Hepp
f93ee3accc First hack of ignoring already tagged items 2016-12-26 23:54:24 +01:00
nath@home
147ced9eaa acousticbrainz: latest adjustments
* Readability and consistency
* Better logging: warn by default for attributes that were not found,
  but don't drown user with info when everything is going well.
2016-11-20 22:45:07 +01:00
nathdwek@laptop
eb1ea6177d acousticbrainz: drop DefaultList, be explicitly careful
* I don't see DefaultList be really helpful in many other cases, so having
  a beets.util.collections module (which could also conflict with the collections
  module from standard library) with only that in it is a little silly.
* It was elegant and concise, but there are implementation issues: it is not
  recommended to subclass builtin types, but the alternatives differ between python
  2 and 3 (subclass sequence or container or collections.abc?), moreover,
  interpreters can differ in the way they map syntaxic sugar to magic functions.
* Also, slicing and negative indexing could do weird things, so the class wouldn't
  be really intuitive and simple at the same time
2016-11-20 22:03:41 +01:00
nathdwek@laptop
1d972b9907 acousticbrainz: rewrite _map_dict_to_scheme:
* Less lazy names
* Separate root function from childs more naturally
* Actually use defaultdict
2016-11-20 22:03:41 +01:00
nathdwek@laptop
324c67191d acousticbrainz: log fetched attributes and values as info 2016-11-20 22:03:41 +01:00
nathdwek@laptop
3979619f9f acousticbrainz: remove redundant comments 2016-11-20 22:03:41 +01:00
nath@home
7a676400dc acousticbrainz: Refactor the json handling part 2016-11-20 22:03:41 +01:00
nath@home
1963b52903 acousticbrainz: Initial cleanup 2016-11-20 22:03:41 +01:00
Jelle Besseling
b4caa0e475 Add BPM data with acousticbrainz
The bpm plugin is a very slow way to add bpm data to songs, using the acousticbrainz plugin is much faster and can doesn't need a new plugin.
2016-07-26 15:42:35 +02:00
Johnny Robeson
a405a072f7 use reduce() from functools 2016-05-26 23:52:35 -04:00
Frederik “Freso” S. Olesen
37b9360706
acousticbrainz plugin: Access acousticbrainz.org over HTTPS. 2016-05-20 01:08:15 +02:00
Adrian Sampson
e54c7eec3d Standardize __future__ imports without parentheses
Since the list is short enough now, we don't need parentheses for the line
wrap. This is a little less ugly.
2016-02-28 15:03:51 -08:00
Peter Kessen
6852ab5472 Removed unicode_literals from plugins
* acousticbrainz
* badfiles
* bpm
2016-02-20 11:49:10 +01:00
Adrian Sampson
04618f9aef acousticbrainz (#1787): Fix typos in keys 2016-01-03 14:17:39 -08:00