Appease flake8

This commit is contained in:
Rahul Ahuja 2019-09-04 20:39:46 -07:00
parent f64bd65ddb
commit 1b05912ab9
3 changed files with 10 additions and 5 deletions

View file

@ -278,7 +278,8 @@ class APIAutotaggerPlugin(BeetsPlugin):
:type artists: list[dict]
:param id_key: Key corresponding to ``artist_id`` value.
:type id_key: str
:param name_key: Keys corresponding to values to concatenate for ``artist``.
:param name_key: Keys corresponding to values to concatenate
for ``artist``.
:type name_key: str
:return: Normalized artist string.
:rtype: str

View file

@ -294,7 +294,9 @@ class DiscogsPlugin(BeetsPlugin):
self._log.warning(u"Release does not contain the required fields")
return None
artist, artist_id = APIAutotaggerPlugin.get_artist([a.data for a in result.artists])
artist, artist_id = APIAutotaggerPlugin.get_artist(
[a.data for a in result.artists]
)
album = re.sub(r' +', ' ', result.title)
album_id = result.data['id']
# Use `.data` to access the tracklist directly instead of the
@ -533,7 +535,9 @@ class DiscogsPlugin(BeetsPlugin):
title = track['title']
track_id = None
medium, medium_index, _ = self.get_track_index(track['position'])
artist, artist_id = APIAutotaggerPlugin.get_artist(track.get('artists', []))
artist, artist_id = APIAutotaggerPlugin.get_artist(
track.get('artists', [])
)
length = self.get_track_length(track['duration'])
return TrackInfo(title, track_id, artist=artist, artist_id=artist_id,
length=length, index=index,

View file

@ -306,8 +306,8 @@ class SpotifyPlugin(APIAutotaggerPlugin):
"""Query the Spotify Search API for the specified ``keywords``, applying
the provided ``filters``.
:param query_type: Item type to search across. Valid types are: 'album',
'artist', 'playlist', and 'track'.
:param query_type: Item type to search across. Valid types are:
'album', 'artist', 'playlist', and 'track'.
:type query_type: str
:param filters: (Optional) Field filters to apply.
:type filters: dict