New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

backend: Remove default impl of PlaylistProvider.playlists #1046

Merged
merged 2 commits into from Mar 18, 2015

Conversation

2 participants
@jodal
Member

jodal commented Mar 17, 2015

The default was insane. For one, because overriding e.g. just the
getter would make the property have a pair of working getter and
setter that are entirely disconnected.

@jodal jodal added this to the v0.20 - Audio cleanup 1 milestone Mar 17, 2015

@@ -277,11 +276,11 @@ def playlists(self):
Read/write. List of :class:`mopidy.models.Playlist`.
"""
return copy.copy(self._playlists)
raise NotImplementedError

This comment has been minimized.

@adamcik

adamcik Mar 17, 2015

Member

Anywhere we should make sure to catch these in our code, MPD perhaps?

This comment has been minimized.

@jodal

jodal Mar 17, 2015

Member

This would blow up on https://github.com/mopidy/mopidy/blob/develop/mopidy/core/playlists.py#L27

Maybe simply change the default to return []?

@jodal jodal force-pushed the jodal:fix/backend-playlists-default-impl branch from de23f4a to 01dad1c Mar 17, 2015

jodal added some commits Mar 17, 2015

backend: Remove default impl of PlaylistProvider.playlists
The default was insane. For one, because overriding e.g. just the
getter would make the property have a pair of working getter and
setter that are entirely disconnected.

@jodal jodal force-pushed the jodal:fix/backend-playlists-default-impl branch from 01dad1c to accc1e7 Mar 17, 2015

@jodal

This comment has been minimized.

Member

jodal commented Mar 17, 2015

That should fix flake8 too.

adamcik added a commit that referenced this pull request Mar 18, 2015

Merge pull request #1046 from jodal/fix/backend-playlists-default-impl
backend: Remove default impl of PlaylistProvider.playlists

@adamcik adamcik merged commit 63db14d into mopidy:develop Mar 18, 2015

2 checks passed

Scrutinizer 5 updated code elements
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details

@jodal jodal deleted the jodal:fix/backend-playlists-default-impl branch Mar 18, 2015

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment