Commit graph

2434 commits

Author SHA1 Message Date
Fabrice Laporte
3e38a33c4a Fix PEP8 2017-05-02 23:37:20 +02:00
Fabrice Laporte
11eb90c758 Fix PEP8 2017-05-02 07:46:51 +02:00
Fabrice Laporte
3e3ad6974c Fix PEP8 2017-05-02 07:30:40 +02:00
Fabrice Laporte
a165d6c00b Fix MusiXmatch text extraction markers 2017-05-01 23:40:09 +02:00
Fabrice Laporte
2bf58a61c3 Decode string with Unicode escape 2017-04-30 23:14:23 +02:00
wordofglass
bb5629ea1d Remove untyped except statements 2017-04-29 00:05:20 +02:00
Jakub Wilk
95a868bb50 Don't hardcode errno constant
The value of ENOENT is architecture-dependent, so don't assume
it's always 2.
2017-04-23 23:28:32 +02:00
Adrian Sampson
fae8fcc932 ftintitle: Clarify indexing
This can only be a two-element array, so just use the index 1. This matches
better with the comments, that say "right-hand side" instead of "the last
value in the list."
2017-04-19 19:08:15 -04:00
Adrian Sampson
9d42728f7f ftintitle: Clarify control flow
Assigning to this variable made it hard to tell what the function was actually
returning.
2017-04-19 19:07:29 -04:00
Adrian Sampson
78f19db511 Merge pull request #2521 from tweitzel/master
add --yes argument to play command
2017-04-19 18:59:50 -04:00
xarph
02aa6191c1 rename --force to --yes in play plugin
fix some pep8 goo
2017-04-19 10:51:44 -07:00
xarph
ffcaf33845 add -f argument to play command 2017-04-18 15:30:24 -07:00
Adrian Sampson
a2eb6fae0b Merge pull request #2518 from jwilk/re.sub
Fix misuse of flags in re.sub() calls
2017-04-15 12:00:09 -04:00
Jakub Wilk
d3664ad5db Fix misuse of flags in re.sub() calls
The 4th argument of re.sub() is maximum number of substitutions,
not flags.
2017-04-15 14:44:19 +02:00
Adrian Sampson
c7801d4cc0 Attempted fix for #2515 (convert on Windows)
On Python 3, this tries to pass through the Unicode filename representation
for paths to the Windows API.
2017-04-14 09:31:30 -04:00
nath@home
920784a42d Play: handle plural in warning output 2017-03-23 22:46:23 +01:00
Jan Solanti
7cf7bc5ff6 Change default aac encoder to FFmpeg's native one
FFmpeg's native aac encoder was declared stable in 3.0 (Feb 15. 2016).
Support for libfaac was removed some time later:
http://git.videolan.org/?p=ffmpeg.git;a=commit;h=dc0f711459e0c682bf9f94ba38d26736e90cff45
2017-03-20 22:15:17 +02:00
Olivier Biesmans
cf384109f0 Make falke8 happy and reference flask doc for the ReverseProxied class 2017-03-19 21:16:26 +00:00
Olivier Biesmans
aa847e52ac Add reverse proxy support 2017-03-19 20:08:39 +00:00
Adrian Sampson
620710b3d7 Merge pull request #2481 from qlyoung/missing-albums
Add ability for 'missing' plugin to show missing albums by library artists
2017-03-18 19:34:28 -04:00
Quentin Young
bf87cab1d8 beetsplug: implement missing -a -t
Produces a count of missing albums without listing them

Signed-off-by: Quentin Young <qlyoung@qlyoung.net>
2017-03-18 19:05:46 -04:00
Quentin Young
b013abae6b beetsplug: cleanup for 'missing -a' code
* Use full name for musicbrainzngs import
* Use beets internal logging facilities
* Match releases by release id
* Convert some strings to Unicode
* Remove unnecessary MB rate-limiting
* Remove unnecessary imports
* Follow beets convention for `--album` option
* Follow beets convention for imperative docstrings
* Simplify method signatures
* Use defaultdict(list) where appropriate
* Clarify missing MBID log message

Signed-off-by: Quentin Young <qlyoung@qlyoung.net>
2017-03-18 18:58:41 -04:00
Quentin Young
339a1ef671 beetsplug: add '-a' to show missing albums to 'missing' plugin
Passing -a to 'beet missing' shows albums missing by all artists
in the library.

Signed-off-by: Quentin Young <qlyoung@qlyoung.net>
2017-03-18 17:52:01 -04:00
inytar
71aab6d743 Remove check for supported formats in absubmit
Also lower the logging to warning if the extractor fails
to analyse a file
2017-03-16 11:26:54 -04:00
inytar
aab84413ec Merge remote-tracking branch 'upstream/master' 2017-03-16 11:08:17 -04:00
Adrian Sampson
5ed2798a76 Merge pull request #2422 from Stunner/master
Embedart plugin asks for confirmation before making changes to item’s…
2017-03-12 11:34:36 -04:00
Adrian Sampson
2dcc3cd4b2 Merge pull request #2468 from beetbox/smartplaylist-multi
smartplaylist: Support overlapping playlist defs
2017-03-07 22:55:36 -05:00
Adrian Sampson
74df2788c0 Merge branch 'master' into Stunner-master 2017-03-06 23:51:10 -05:00
Adrian Sampson
8ce7b49ed8 Default to confirm 2017-03-06 23:45:29 -05:00
Adrian Sampson
f0f55d11ec Rename _confirmation to _confirm 2017-03-06 23:43:24 -05:00
Adrian Sampson
f985970b25 Simplify scope of _confirmation and formatting 2017-03-06 23:42:20 -05:00
Adrian Sampson
3a436bb33d Remove explicit format
We now use the default formats from the configuration.
2017-03-06 23:38:16 -05:00
Adrian Sampson
eddbab63bd Remove extraneous blank line 2017-03-06 23:37:33 -05:00
Adrian Sampson
430595825f Rename parameter to be more sensible
We don't just take items; they're either items or albums.
2017-03-06 23:37:04 -05:00
Adrian Sampson
c8499eb56d _confirmation does not need to be a closure 2017-03-06 23:34:53 -05:00
Adrian Sampson
1fbbcf65fd Fix some confusing indentation 2017-03-06 23:29:09 -05:00
Adrian Sampson
ad4cd7a447 Fix #2469: Beatport track limit
It looks like the API uses pagination, and the default page size is 10. An
easy fix is to just request lots of tracks per page (here, 100). A nicer thing
to do in the future would be to actually traverse multiple pages.
2017-03-06 22:58:00 -05:00
Adrian Sampson
8d14e1b6df smartplaylist: Support overlapping playlist defs
See http://discourse.beets.io/t/beets-path-handling-for-delimited-fields/44
2017-03-06 19:07:06 -05:00
Adrian Sampson
d356356111 Fix #2466: GIO returns bytes, so decode them 2017-03-03 11:59:50 -06:00
Adrian Sampson
6300d0c5a0 Merge pull request #2411 from Pauligrinder/patch-2
Add a plugin to update a Kodi music library
2017-03-03 10:01:00 -06:00
Pauligrinder
659c17f825 Code fixed according to flake8 2017-03-01 11:11:54 +02:00
Pauligrinder
f315a17bb2 Added the copyright header
Also added config['kodi']['pwd'].redact = True as suggested.
2017-03-01 10:39:40 +02:00
Teh Awesomer
1305c9407f mbsubmit plugin : numeric sort in print_tracks (for >=10 track releases) 2017-02-25 12:01:34 -08:00
Adrian Sampson
77a6b0edf8 duplicates: Fix 2nd bug in #2444 about path types 2017-02-21 22:00:31 -05:00
Adrian Sampson
74c0e0d6e9 Fix default for user_token
Always match the expected type.
2017-02-21 13:56:20 -05:00
Adrian Sampson
a29b29f533 Docs improvements for #2447 2017-02-21 09:49:22 -05:00
Adrian Sampson
1373c0c7b8 Merge pull request #2447 from robbat2/discogs-simpleauth
discogs: support simple auth.
2017-02-21 09:47:15 -05:00
Aaron Jubbal
864aa11ec5 Merge branch 'master' into master 2017-02-21 04:43:45 -08:00
Robin H. Johnson
3e4c9b8c06
discogs: support simple auth.
The official OAuth authentication seems to have broken, so allow usage
of simple configuration instead.

See-Also: https://github.com/discogs/discogs_client/issues/78
Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
2017-02-20 20:20:20 -08:00
Jacob Gillespie
b4efecb709 Add option to hardlink when importing 2017-02-19 15:56:13 -06:00
Adrian Sampson
0a4709f7ef lyrics: Tolerate empty Google response (#2437) 2017-02-13 16:54:56 -05:00
Aaron
733c1839fb Addressed coding style issue. 2017-02-13 02:56:54 -08:00
Aaron
3e13971c54 Some code cleanup/consolidation. 2017-02-13 02:30:01 -08:00
Aaron
d1ac893915 Style changes to pass PEP8 tests. 2017-02-13 01:58:31 -08:00
Aaron
3361aaafda Embedart plugin asks for confirmation before making changes to item’s artwork. 2017-02-13 01:58:31 -08:00
Adrian Sampson
8087e82891 lyrics: Use Requests for Google backend (fix #2437) 2017-02-12 10:30:22 -05:00
Adrian Sampson
86c8cffa6c Fix some whitespace (#2433) 2017-02-11 19:24:47 -05:00
Adrian Sampson
e2b9a3fca6 Merge pull request #2433 from karpinski/badfiles-checkers
badfiles: continue execution to other files instead of stopping after a checker error
2017-02-11 19:22:15 -05:00
Marcin Karpinski
8ef9f68843 badfiles: only output corrupt files by default
badfiles now only outputs corrupt files by default — to get full output enable verbose mode using -v or --verbose
2017-02-10 21:51:23 +00:00
karpinski
b46fb956b7 Making logging level consistent when checker is not found. 2017-02-10 12:49:16 +01:00
karpinski
291803d49a Fixing a small typo. 2017-02-10 12:49:16 +01:00
karpinski
ffca8f549f Allowing the execution to continue to other files if validator is not found or exits with an error. 2017-02-10 12:49:16 +01:00
Adrian Sampson
0216ef294a badfiles: Python 3 compatibility
Discovered while working on #2428 that we were using an implicit bytes-to-str
conversion on the extension. This broke dict lookup on Python 3.
2017-02-04 13:43:23 -06:00
Adrian Sampson
0131ce263d badfiles: Better logging and error handling (#2428) 2017-02-04 13:42:24 -06:00
Jeffrey Aylesworth
8638157e17 Change license and email address in mbcollection plugin. 2017-01-30 23:37:01 -05:00
wordofglass
bc582701ff fetchart: Internally pass settings in a cleaner way.
Dump the 'extra' dictionary which only duplicated attributes of the
plugin onject in favor of passing a reference to the plugin directly.
2017-01-25 00:01:05 +01:00
Artem Utin
40eef2056c Add changelog entry, wrap long comment lines. 2017-01-24 11:41:55 +10:00
Artem Utin
2ab1f3ae89 More general approach to multiple on_play calls for the same song - now it ignores such calls, if time between calls was below threshold 2017-01-23 23:15:14 +10:00
Pauligrinder
ca8832809d Removed a couple of unnecessary imports
json and requests.BasicAuthentication
2017-01-23 13:14:36 +02:00
Pauligrinder
77d155cdea Add a plugin to update a Kodi music library
I created one for an older version before, but it didn't work since the change to Python 3. So I created a new one that works.
2017-01-23 12:43:40 +02:00
Adrian Sampson
44963598e8 Remove unused import 2017-01-21 23:32:36 -08:00
Adrian Sampson
ca904a9d0c mpdstats: Fix Python 3 compatibility (fix #2405)
We previously needed a hack to get the client to consume and produce Unicode strings. The library has since added Unicode support, behind a constructor flag. We can remove the hack now, which was causing a crash on Python 3 because the library uses Unicode by default there, and instead use its built-in support.
2017-01-21 23:21:11 -08:00
Adrian Sampson
958ad430fc bpd: Use integers for time values (fix 2394) 2017-01-17 11:37:10 -08:00
Steve Johnson
926dce241c Use util.displayable_path instead of naive .decode() 2017-01-15 11:25:03 -08:00
Steve Johnson
e3707e45f3 Maybe fix code and tests for Windows 2017-01-15 11:21:59 -08:00
Steve Johnson
e2be6ba781 Query path with bytestring. Might fix tests. 2017-01-15 11:21:59 -08:00
Steve Johnson
4434569ddc beets.library.Library adds custom bytelower function to all connections, not just one 2017-01-15 11:21:59 -08:00
Steve Johnson
866a650bc0 Rename /item/by_path to /item/path and use PathQuery instead of direct file access 2017-01-15 11:21:33 -08:00
Steve Johnson
05bc4996a8 Rename and invert new config option 2017-01-15 11:21:33 -08:00
Steve Johnson
50ea74635b Fix tests I broke 2017-01-15 11:21:33 -08:00
Steve Johnson
f6cb46d490 Fix broken tests (no new ones yet) 2017-01-15 11:21:33 -08:00
Steve Johnson
43936cd84c /item/at_path/ endpoint
More at_path

/item/by_path docs
2017-01-15 11:21:33 -08:00
Steve Johnson
29d61ca634 web.exclude_paths_from_items option
More exclude_paths_from_items
2017-01-15 11:21:33 -08:00
Mike Cameron
c58c49d77f Fixed trailing whitespace issue. Changed alternate track property name. 2017-01-10 18:39:01 -05:00
Mike Cameron
24b02e8215 Merge remote-tracking branch 'upstream/master' 2017-01-10 17:33:45 -05:00
Adrian Sampson
998e6ac1c7 Remove unused import 2017-01-10 14:54:17 -05:00
Adrian Sampson
bc93a11141 Fix #2382: replaygain backend parsing on Python 3 2017-01-10 14:45:57 -05:00
Adrian Sampson
153b01e5a6 replaygain: Don't muck with logging level
This is now handled by the central logging infrastructure; no need to change
it here. I think this must be a leftover from the era when plugins had to
explicitly muck with their verbosity level, but even still it doesn't make
sense to do set the level to INFO unconditionally...
2017-01-10 14:24:18 -05:00
Adrian Sampson
2706339a83 Fix #2381: mpdupdate on Python 3
Communicate bytes over the socket, obvi.
2017-01-10 12:22:30 -05:00
Adrian Sampson
0b5b20d799 Robust import of distutils submodule (fix #2376)
This would fail if the `spawn` module in the `distutils` package was not
already imported somewhere else.
2017-01-07 17:15:13 -05:00
Adrian Sampson
6b9d766082 Remove compatibility with misspelled config option
This has been hanging around long enough; it's about time to drop the old
name.
2017-01-07 17:09:51 -05:00
Adrian Sampson
c9ec5e411c A little fiddling with embyupdate
Clean up some wording w/r/t efbd58cd55.
2017-01-07 17:07:01 -05:00
Adrian Sampson
ffa22d6ce1 Merge pull request #2360 from diomekes/importer-play
play: Add prompt choice to importer
2017-01-07 17:02:22 -05:00
diomekes
8d613425fd small docstring rewrite 2017-01-06 23:46:16 -05:00
Marvin Steadfast
efbd58cd55 embyupdate: fix bug that config for password and api is needed
even if it only used api key it needed the password key. this is fixed
now.
2017-01-06 11:52:53 +01:00
diomekes
8d97257647 use shlex_split, clean up code and docs 2017-01-03 22:10:35 -05:00
Adrian Sampson
d389ac15e1 Use HTTPS for MS translator API (from #2247) 2017-01-02 21:00:01 -05:00
Adrian Sampson
fbc0f322f6 Merge branch 'tigranl-https_fix' 2017-01-02 20:54:17 -05:00
Adrian Sampson
f941fd42de Always use SSL on servers that don't require SNI
I did a little audit using the `openssl` command-line tool to find the servers
that don't require SNI. Here's what I found:

icbrainz.org: SNI
images.weserv.nl: inconclusive, but docs say yes SNI
coverartarchive.org: SNI
webservice.fanart.tv: *no* SNI
dbpedia.org: *no* SNI
en.wikipedia.org: *no* SNI
ws.audioscrobbler.com: *no* SNI
api.microsofttranslator.com: *no* SNI

In summary, *only* MusicBrainz and CoverArtArchive were found to require SNI.
So I'm using SSL unconditionally on all the other sites.
2017-01-02 20:39:10 -05:00
inytar
a5aee3f677 Absubmit close temporary file
Fix error when deleting the file under Windows
2017-01-02 14:05:59 -05:00