diff --git a/docs/changes.rst b/docs/changes.rst index 32115a95..968ef255 100644 --- a/docs/changes.rst +++ b/docs/changes.rst @@ -50,6 +50,9 @@ v0.6.0 (in development) - Unescape all incoming MPD requests. (Fixes: :issue:`113`) +- Increase the maximum number of results returned by Spotify searches from 32 + to 100. + **multi-backend changes** - Remove `destroy()` methods from backend controller and provider APIs, as it diff --git a/mopidy/backends/spotify/session_manager.py b/mopidy/backends/spotify/session_manager.py index 9c8853e6..9a883d23 100644 --- a/mopidy/backends/spotify/session_manager.py +++ b/mopidy/backends/spotify/session_manager.py @@ -151,9 +151,12 @@ class SpotifySessionManager(BaseThread, PyspotifySessionManager): """Search method used by Mopidy backend""" def callback(results, userdata=None): # TODO Include results from results.albums(), etc. too + # TODO Consider launching a second search if results.total_tracks() + # is larger than len(results.tracks()) playlist = Playlist(tracks=[ SpotifyTranslator.to_mopidy_track(t) for t in results.tracks()]) queue.put(playlist) self.connected.wait() - self.session.search(query, callback) + self.session.search(query, callback, track_count=100, + album_count=0, artist_count=0)