Commit graph

2213 commits

Author SHA1 Message Date
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
Adrian Sampson
62e9a15f4d Fix a copy n' paste error found by flake8 2016-11-16 12:03:07 -05:00
nath@home
2e78628507 convert: Don't ask for confirmation if query result is empty 2016-11-13 17:46:29 +01:00
nath@home
d53b677e0f convert: initial cleanup of convert_func
Get cli options and configuration in a more readable, uniform way
2016-11-13 00:20:01 +01:00
michaelbub
0a88338f8b obey style guide 2016-11-11 16:23:32 +01:00
michaelbub
0bdc621d99 sanitizing playlist name AFTER values have been filled in and updated test accordingly 2016-11-11 15:21:34 +01:00
michaelbub
5942adba01 fixed/updated test to consider sanitized playlist names 2016-11-11 10:07:25 +01:00
michaelbub
3e53d4caff sanitize playlist names
Make e. g.
- name: $albumartist/$year-$album.m3u'
work when album data includes non fs-friendly characters
2016-11-10 13:05:18 +01:00
root
f37df2dbd4 Whitespace for flake8. 2016-11-08 16:56:13 -08:00
root
acd5c6404f missing plugin, modify "missing" attribute by modifying album_types,
making it of type INTEGER. also changelog for above.
2016-11-08 16:23:57 -08:00
nathdwek@laptop
a0877dc092 images: Make sure all jpegs work everywhere
Apply #1545 to a public function used everywhere
2016-11-08 18:48:44 +01:00
Max Ammann
7242c5ed03 Revert "Expose the relative path to the library instead of omitting the 'path' variable"
This reverts commit 5e8ac9e4a5, because of
a slowdown. Resolves #2182.
2016-10-26 23:08:44 +02:00
kooimens
373cf19f8b Fix discogs disc field is set to zero
Fixes #587. The disc field is only zero when there is only one medium, so I think this will do the trick. I wasn't able to reproduce the real problem within the code. This is just a small workaround.
2016-10-17 19:51:03 +02:00
Diego Moreda
1f4bef9e61 discogs: docstring style fix 2016-10-10 20:30:21 +02:00
Diego Moreda
f4907ca5d0 discogs: handle nested subtracks, add try block
Modify coalesce_tracks() in order to handle the case where subtracks
are defined inside an index track (as `sub_tracks` attribute),
reorganizing the if logic to avoid duplicated code.

Add a try..catch block enclosing the call to clean_tracklist, as a
measure for avoiding side effects (and reverting to just parsing the
raw_list if there are any problems).
2016-10-10 19:59:42 +02:00
Diego Moreda
fb398c5f2c discogs: add medium_total to tracks (#415) 2016-10-10 17:46:41 +02:00
Diego Moreda
1148acaaf1 discogs: revise position regexp, add tests, tox
Revise the regular expression used for extracting information from a
discogs position, making the subtrack_index only be matched if one of
the other groups is matched as well. Split the definition into several
lines in order to try to document it a bit more clearly.
Add unit tests for position parsing and non standard positions.
Fix the underscore on tox dependency.
2016-10-10 17:42:27 +02:00
Diego Moreda
e7f2a111e4 discogs: add test dependencies, fix spelling 2016-10-09 17:57:36 +02:00
Diego Moreda
be223d966e discogs: coalesce subtracks (#1543)
Detect subtracks and merge them into a single track, taking into account
the index tracks if present. This includes a revision of the regular
expression used for converting a discogs "position" into medium, medium
index and subtrack index pieces, following the standard discogs
positions (12.2.9).
2016-10-07 19:09:09 +02:00
Diego Moreda
c55885c9e8 discogs: take into account two-sided media (#1762)
Revise the discogs plugin so two-sided mediums are taking into account
and each pair of consecutive *sides* is treated as single *medium*.
2016-10-07 19:01:50 +02:00
Diego Moreda
911117ef49 discogs: set media on tracks (#1921)
Set the media for all the tracks when fetching a release using discogs,
as autotag.apply_metadata requires it in order to work properly.
2016-10-06 19:49:43 +02:00
Adrian Sampson
4ae02e0d27 Merge pull request #2211 from heylookltsme/better-genre
Proposal: Add specificity option to lastgenre plugin
2016-09-27 09:07:39 -04:00
Corinne Hoener
a7e3bf2d0b third time's a charm 2016-09-27 06:21:51 -04:00
Corinne Hoener
1c9202cc86 moar indents! 2016-09-26 21:21:15 -04:00
Corinne Hoener
c10fe1e126 change option name to prefer_specific 2016-09-26 19:06:34 -04:00
Corinne Hoener
be5ce3194f better syntax; better comments 2016-09-26 19:02:10 -04:00
Corinne Hoener
288ff6ba19 Add specificity option to lastgenre in order to prefer the most specific genres 2016-09-26 16:13:04 -04:00
Fabrice Laporte
0140f2f287 Merge pull request #2206 from Kraymer/issue2205
Issue2205: search for lyrics using part of song title preceding ':'
2016-09-25 21:24:56 +02:00
Fabrice Laporte
7226624405 replace strip_part() by generate_alternatives()
Delegate the update of titles and artists lists to the helper
generate_alternatives() function.
2016-09-25 19:37:14 +02:00
Fabrice Laporte
e2703b9a7c always yield item artist and title first
Rather than using an unordered set for storing pairs, append to a list
and build an OrderedDict from it to filter duplicated strings while
keeping order.
2016-09-25 15:46:22 +02:00
Johnny Robeson
3db656a685 use py3_path on gstreamer location prop setters
Location properties require strings, so we give them to them!
2016-09-24 01:16:56 -04:00
Fabrice Laporte
8b4f39da42 lyrics: search for song title part preceding colon. fix #2205 2016-09-23 22:23:32 +02:00
Fabrice Laporte
4b702b338e lyrics: reduce code duplication in search_pairs() 2016-09-23 22:21:00 +02:00
Johnny Robeson
6b73aa25d2 Use b'' in discogs medium query regex
Since the first arg to `re.sub()` is bytes, thus must be the
replacement string.
2016-09-20 17:38:39 -04:00
Johnny Robeson
db782a2404 wrap 2 results in a list in cue and random plugin 2016-09-14 00:40:53 -04:00
Cody W. Opel
d384b07914 fromfilename: fix dict view conversion for python3 (fix #2195)
dict.values() returns a view rather than a list in python3
2016-09-12 09:29:32 -04:00
Adrian Sampson
d00c0fb5cf Replace varargs_callback in duplicates
Now you just use `-k KEY1 -k KEY2`, which seems more natural to me anyway.
2016-09-10 05:13:06 -04:00
Adrian Sampson
f8a8388e0c Avoid using None when format is unspecified 2016-09-07 21:47:31 -04:00
Adrian Sampson
15a5512ea5 Require Unicode format strings
Fallout from #2188. Following @jrobeson's suggestion, I just turned the check
in LibModel.__format__ into an assert. This turned up a few badly-behaved
clients, which are also fixed.
2016-09-07 21:42:59 -04:00
Adrian Sampson
ed8d04f594 Unicode templates in duplicates (fix #2188) 2016-09-07 21:04:05 -04:00
Johnny Robeson
7a2bdf502f s/utf8/utf-8/ in all encoding/decoding contexts
This matches up with the python documentation.
2016-09-06 23:10:24 -04:00
nathdwek@laptop
3acd44260a Apply #2175 to mpdstats to keep consistency 2016-08-26 18:17:37 +02:00
Thiago de Arruda
9963fd0432 mpdupdate: Support $MPD_HOST environment variable.
This environment variable is also used by mpc. See
http://linux.die.net/man/1/mpc for details.
2016-08-26 11:36:39 -03:00
Marvin Steadfast
5592499b31 embyupdate: backwards compatible hostname
`host` takes `localhost`, `http://localhost` and `https://`.
2016-08-26 12:28:48 +02:00
Marvin Steadfast
a282d4abc5 embyupdate: Fix authentication header problem
There was a problem with the authentication header in the latest
versions. The header creation function changed to fix that. Username and
passwort authentication should work again.

The `host` config variable takes now a full hostname. For example
`http://localhost` instead of just `localhost`. This makes it easier to
use https hosts.
2016-08-26 10:29:08 +02:00
Johnny Robeson
6bedbd84df removebyte conversion/literals for command args
Paths are obviously untouched.

We definitely don't need these as they are entirely ascii.
2016-08-25 03:37:30 -04:00