From 17c30c8bcd59526d5ed199bf851e0b3626896e56 Mon Sep 17 00:00:00 2001 From: Stein Magnus Jodal Date: Wed, 3 Nov 2010 00:17:53 +0100 Subject: [PATCH 01/11] docs: Update refs to BaseMixer --- docs/api/backends/controllers.rst | 2 +- docs/api/mixers.rst | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/docs/api/backends/controllers.rst b/docs/api/backends/controllers.rst index 88bb48ff..28112cf7 100644 --- a/docs/api/backends/controllers.rst +++ b/docs/api/backends/controllers.rst @@ -32,7 +32,7 @@ seek. Mixer controller ================ -Manages volume. See :class:`mopidy.mixers.BaseMixer`. +Manages volume. See :class:`mopidy.mixers.base.BaseMixer`. Current playlist controller diff --git a/docs/api/mixers.rst b/docs/api/mixers.rst index 434637f3..6daa7a4e 100644 --- a/docs/api/mixers.rst +++ b/docs/api/mixers.rst @@ -24,10 +24,10 @@ enable one of the hardware device mixers, you must the set :attr:`mopidy.settings.MIXER` setting to point to one of the classes found below, and possibly add some extra settings required by the mixer you choose. -All mixers should subclass :class:`mopidy.mixers.BaseMixer` and override +All mixers should subclass :class:`mopidy.mixers.base.BaseMixer` and override methods as described below. -.. automodule:: mopidy.mixers +.. automodule:: mopidy.mixers.base :synopsis: Mixer API :members: :undoc-members: From 95aa739c96ede3fb5a2a4c6486fb2eb14eef6e56 Mon Sep 17 00:00:00 2001 From: Stein Magnus Jodal Date: Wed, 3 Nov 2010 00:35:27 +0100 Subject: [PATCH 02/11] Update changelog --- docs/api/backends/concepts.rst | 2 ++ docs/changes.rst | 43 ++++++++++++++++++++++++++++++---- 2 files changed, 41 insertions(+), 4 deletions(-) diff --git a/docs/api/backends/concepts.rst b/docs/api/backends/concepts.rst index fd7b4d13..0d476213 100644 --- a/docs/api/backends/concepts.rst +++ b/docs/api/backends/concepts.rst @@ -1,3 +1,5 @@ +.. _backend-concepts: + ********************************************** The backend, controller, and provider concepts ********************************************** diff --git a/docs/changes.rst b/docs/changes.rst index c3df7d85..add4cfc6 100644 --- a/docs/changes.rst +++ b/docs/changes.rst @@ -12,10 +12,45 @@ No description yet. **Changes** -- Install ``mopidy.desktop`` file that makes Mopidy available from e.g. Gnome - application menus. -- Add :command:`mopidy-scan` command to generate ``tag_cache`` files without - any help from the original MPD server. +- Packaging and distribution: + + - Install ``mopidy.desktop`` file that makes Mopidy available from e.g. Gnome + application menus. + - Create infrastructure for creating Debian packages of Mopidy. + +- Local backend: + + - Add :command:`mopidy-scan` command to generate ``tag_cache`` files without + any help from the original MPD server. + +- Models: + + - Rename and generalize ``Playlist._with(**kwargs)`` to + :meth:`mopidy.models.ImmutableObject.copy`. + +- Introduce the :ref:`provider concept `. Split the backend + API into a :ref:`backend controller API ` (for + frontend use) and a :ref:`backend provider API ` (for + backend implementation use), which includes the following changes: + + - Rename ``BaseBackend`` to :class:`mopidy.backends.base.Backend`. + - Rename ``BaseCurrentPlaylistController`` to + :class:`mopidy.backends.base.CurrentPlaylistController`. + - Split ``BaseLibraryController`` to + :class:`mopidy.backends.base.LibraryController` and + :class:`mopidy.backends.base.BaseLibraryProvider`. + - Split ``BasePlaybackController`` to + :class:`mopidy.backends.base.PlaybackController` and + :class:`mopidy.backends.base.BasePlaybackProvider`. + - Split ``BaseStoredPlaylistsController`` to + :class:`mopidy.backends.base.StoredPlaylistsController` and + :class:`mopidy.backends.base.BaseStoredPlaylistsProvider`. + +- Other API and package structure cleaning: + + - Move ``BaseMixer`` to :class:`mopidy.mixers.base.BaseMixer`. + - Add docs for the current non-stable output API, + :class:`mopidy.outputs.base.BaseOutput`. 0.2.0 (2010-10-24) From e4f006030b52b976bd51d2dd7312df9afb0b51d7 Mon Sep 17 00:00:00 2001 From: Stein Magnus Jodal Date: Wed, 3 Nov 2010 00:45:48 +0100 Subject: [PATCH 03/11] Update changelog --- docs/changes.rst | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/docs/changes.rst b/docs/changes.rst index add4cfc6..6c9f99f1 100644 --- a/docs/changes.rst +++ b/docs/changes.rst @@ -12,6 +12,19 @@ No description yet. **Changes** +- Settings: + + - Automatically expand ``~`` to the user's home directory in settings with + names ending in ``_PATH`` or ``_FILE``. + - Rename the following settings. The settings validator will warn you if you + need to change your local settings. + + - ``LOCAL_MUSIC_FOLDER`` to :attr:`mopidy.settings.LOCAL_MUSIC_PATH` + - ``LOCAL_PLAYLIST_FOLDER`` to + :attr:`mopidy.settings.LOCAL_PLAYLIST_PATH` + - ``LOCAL_TAG_CACHE`` to :attr:`mopidy.settings.LOCAL_TAG_CACHE_PATH` + - ``SPOTIFY_LIB_CACHE`` to :attr:`mopidy.settings.SPOTIFY_CACHE_PATH` + - Packaging and distribution: - Install ``mopidy.desktop`` file that makes Mopidy available from e.g. Gnome @@ -22,11 +35,14 @@ No description yet. - Add :command:`mopidy-scan` command to generate ``tag_cache`` files without any help from the original MPD server. + - Support UTF-8 encoded tag caches with non-ASCII characters. - Models: - Rename and generalize ``Playlist._with(**kwargs)`` to :meth:`mopidy.models.ImmutableObject.copy`. + - Add ``musicbrainz_id`` field to :class:`mopidy.models.Artist`, + :class:`mopidy.models.Album`, and :class:`mopidy.models.Track`. - Introduce the :ref:`provider concept `. Split the backend API into a :ref:`backend controller API ` (for From a44a86acc8f28070bef2e1a84452ec4529f77b75 Mon Sep 17 00:00:00 2001 From: Stein Magnus Jodal Date: Wed, 3 Nov 2010 00:51:36 +0100 Subject: [PATCH 04/11] Update changelog --- docs/changes.rst | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/docs/changes.rst b/docs/changes.rst index 6c9f99f1..d957e608 100644 --- a/docs/changes.rst +++ b/docs/changes.rst @@ -14,15 +14,15 @@ No description yet. - Settings: - - Automatically expand ``~`` to the user's home directory in settings with - names ending in ``_PATH`` or ``_FILE``. + - Automatically expand ``~`` to the user's home directory and make the path + absolute for settings with names ending in ``_PATH`` or ``_FILE``. - Rename the following settings. The settings validator will warn you if you need to change your local settings. - ``LOCAL_MUSIC_FOLDER`` to :attr:`mopidy.settings.LOCAL_MUSIC_PATH` - ``LOCAL_PLAYLIST_FOLDER`` to :attr:`mopidy.settings.LOCAL_PLAYLIST_PATH` - - ``LOCAL_TAG_CACHE`` to :attr:`mopidy.settings.LOCAL_TAG_CACHE_PATH` + - ``LOCAL_TAG_CACHE`` to :attr:`mopidy.settings.LOCAL_TAG_CACHE_FILE` - ``SPOTIFY_LIB_CACHE`` to :attr:`mopidy.settings.SPOTIFY_CACHE_PATH` - Packaging and distribution: From 8b5c3cfadc75db6ca12947e5c836bb36ba22bf49 Mon Sep 17 00:00:00 2001 From: Stein Magnus Jodal Date: Tue, 9 Nov 2010 23:51:12 +0100 Subject: [PATCH 05/11] docs: Update donations section --- docs/authors.rst | 21 ++++++++++++++------- 1 file changed, 14 insertions(+), 7 deletions(-) diff --git a/docs/authors.rst b/docs/authors.rst index f56242a5..01e810e4 100644 --- a/docs/authors.rst +++ b/docs/authors.rst @@ -10,13 +10,20 @@ Contributors to Mopidy in the order of appearance: - Kristian Klette -Donations -========= +Showing your appreciation +========================= If you already enjoy Mopidy, or don't enjoy it and want to help us making -Mopidy better, you can `donate money `_ to -Mopidy's development. +Mopidy better, the best way to do so is to contribute back to the community. +You can contribute code, documentation, tests, bug reports, or help other +users, spreading the word, etc. + +If you want to show your appreciation in a less time consuming way, you can +`flattr us `_, or `donate money +`_ to Mopidy's development. + +We promise that any money donated -- to Pledgie, not Flattr, due to the size of +the amounts -- will be used to cover costs related to Mopidy development, like +service subscriptions (Spotify, Last.fm, etc.) and hardware devices like an +used iPod Touch for testing Mopidy with MPod. -Any donated money will be used to cover service subscriptions (e.g. Spotify -and Last.fm) and hardware devices (e.g. an used iPod Touch for testing Mopidy -with MPod) needed for developing Mopidy. From 97f31d3cadb4d6b1de10ba27145f01e21a7c88ad Mon Sep 17 00:00:00 2001 From: Stein Magnus Jodal Date: Fri, 19 Nov 2010 22:06:41 +0100 Subject: [PATCH 06/11] docs: Fix module headers --- docs/modules/frontends/lastfm.rst | 6 +++--- docs/modules/frontends/mpd.rst | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/docs/modules/frontends/lastfm.rst b/docs/modules/frontends/lastfm.rst index bd3e218e..a726f4a2 100644 --- a/docs/modules/frontends/lastfm.rst +++ b/docs/modules/frontends/lastfm.rst @@ -1,6 +1,6 @@ -****************************** -:mod:`mopidy.frontends.lastfm` -****************************** +*************************************************** +:mod:`mopidy.frontends.lastfm` -- Last.fm Scrobbler +*************************************************** .. automodule:: mopidy.frontends.lastfm :synopsis: Last.fm scrobbler frontend diff --git a/docs/modules/frontends/mpd.rst b/docs/modules/frontends/mpd.rst index 6361e909..35128e70 100644 --- a/docs/modules/frontends/mpd.rst +++ b/docs/modules/frontends/mpd.rst @@ -1,6 +1,6 @@ -*************************** -:mod:`mopidy.frontends.mpd` -*************************** +***************************************** +:mod:`mopidy.frontends.mpd` -- MPD server +***************************************** .. automodule:: mopidy.frontends.mpd :synopsis: MPD frontend From f307f86620874abfcf37ab457a5b7f1efd23578b Mon Sep 17 00:00:00 2001 From: Stein Magnus Jodal Date: Fri, 19 Nov 2010 22:38:19 +0100 Subject: [PATCH 07/11] docs: Update roadmap --- docs/development/roadmap.rst | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/docs/development/roadmap.rst b/docs/development/roadmap.rst index 2b0cf2ba..175c62ac 100644 --- a/docs/development/roadmap.rst +++ b/docs/development/roadmap.rst @@ -27,11 +27,11 @@ Possible targets for the next version - Write-support for Spotify, i.e. playlist management. - Virtual directories with e.g. starred tracks from Spotify. - - Support for 320 kbps audio. + - **[WIP: possibly v0.3]** Support for 320 kbps audio. - Local backend: - - Better library support. + - Better music library support. - **[DONE: v0.3]** A script for creating a tag cache. - An alternative to tag cache for caching metadata, i.e. Sqlite. @@ -43,7 +43,7 @@ Stuff we want to do, but not right now, and maybe never - Packaging and distribution: - - **[PENDING]** Create `Homebrew `_ + - **[BLOCKED]** Create `Homebrew `_ recipies for all our dependencies and Mopidy itself to make OS X installation a breeze. See `Homebrew's issue #1612 `_. @@ -68,8 +68,9 @@ Stuff we want to do, but not right now, and maybe never - Publish the server's presence to the network using `Zeroconf `_/Avahi. - **[WIP: feature/mpris-frontend]** D-Bus/`MPRIS `_ - - REST/JSON web service with a jQuery client as example application. Maybe - based upon `Tornado `_ and `jQuery + - **[WIP: feature/http-frontend]** REST/JSON web service with a jQuery client + as example application. Maybe based upon `Tornado + `_ and `jQuery Mobile `_. - DNLA/UPnP so Mopidy can be controlled from i.e. TVs. - `XMMS2 `_ From 133a22ef978108fdfd61706558729fee7c2a5925 Mon Sep 17 00:00:00 2001 From: Johannes Knutsen Date: Tue, 23 Nov 2010 00:26:23 +0100 Subject: [PATCH 08/11] add SPOTIFY_HIGH_BITRATE setting to enable streaming of Spotify's high bitrate streams --- mopidy/backends/libspotify/session_manager.py | 6 ++++++ mopidy/settings.py | 5 +++++ 2 files changed, 11 insertions(+) diff --git a/mopidy/backends/libspotify/session_manager.py b/mopidy/backends/libspotify/session_manager.py index 5831b713..e70e8cfa 100644 --- a/mopidy/backends/libspotify/session_manager.py +++ b/mopidy/backends/libspotify/session_manager.py @@ -36,6 +36,12 @@ class LibspotifySessionManager(SpotifySessionManager, BaseThread): logger.info(u'Connected to Spotify') self.session = session self.connected.set() + if settings.SPOTIFY_HIGH_BITRATE: + logger.debug(u'Prefer high bitrate') + self.session.set_preferred_bitrate(1) + else: + logger.debug(u'Prefer normal bitrate') + self.session.set_preferred_bitrate(0) def logged_out(self, session): """Callback used by pyspotify""" diff --git a/mopidy/settings.py b/mopidy/settings.py index 4f60ee99..dc315064 100644 --- a/mopidy/settings.py +++ b/mopidy/settings.py @@ -183,3 +183,8 @@ SPOTIFY_USERNAME = u'' #: #: Used by :mod:`mopidy.backends.libspotify`. SPOTIFY_PASSWORD = u'' + +#: Do you prefer high bitrate (320k)? +#: +#: Used by :mod:`mopidy.backends.libspotify`. +SPOTIFY_HIGH_BITRATE = False From 975b264c2d70797184c806f65b03cf3549448895 Mon Sep 17 00:00:00 2001 From: Johannes Knutsen Date: Tue, 23 Nov 2010 00:33:14 +0100 Subject: [PATCH 09/11] set connection connected after preferred bitrate is set --- mopidy/backends/libspotify/session_manager.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mopidy/backends/libspotify/session_manager.py b/mopidy/backends/libspotify/session_manager.py index e70e8cfa..8a79088f 100644 --- a/mopidy/backends/libspotify/session_manager.py +++ b/mopidy/backends/libspotify/session_manager.py @@ -35,13 +35,13 @@ class LibspotifySessionManager(SpotifySessionManager, BaseThread): """Callback used by pyspotify""" logger.info(u'Connected to Spotify') self.session = session - self.connected.set() if settings.SPOTIFY_HIGH_BITRATE: logger.debug(u'Prefer high bitrate') self.session.set_preferred_bitrate(1) else: logger.debug(u'Prefer normal bitrate') self.session.set_preferred_bitrate(0) + self.connected.set() def logged_out(self, session): """Callback used by pyspotify""" From 73ed9920c43d741751ba5c17318d94c5fd1bffe5 Mon Sep 17 00:00:00 2001 From: Johannes Knutsen Date: Tue, 23 Nov 2010 00:36:02 +0100 Subject: [PATCH 10/11] Document the default value on the Spotify preferred bitrate setting --- mopidy/settings.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/mopidy/settings.py b/mopidy/settings.py index dc315064..1aaa4318 100644 --- a/mopidy/settings.py +++ b/mopidy/settings.py @@ -187,4 +187,8 @@ SPOTIFY_PASSWORD = u'' #: Do you prefer high bitrate (320k)? #: #: Used by :mod:`mopidy.backends.libspotify`. +# +#: Default:: +#: +#: SPOTIFY_HIGH_BITRATE = False # 160k SPOTIFY_HIGH_BITRATE = False From 9cfd1679795cff6cef83bd074d2f83d87f2df40f Mon Sep 17 00:00:00 2001 From: Stein Magnus Jodal Date: Tue, 23 Nov 2010 00:56:10 +0100 Subject: [PATCH 11/11] Require upgrade of libspotify to 0.0.6, and pyspotify from the mopidy branch --- docs/changes.rst | 11 +++++++++++ docs/installation/libspotify.rst | 18 ++++++++++++------ 2 files changed, 23 insertions(+), 6 deletions(-) diff --git a/docs/changes.rst b/docs/changes.rst index d957e608..3a030145 100644 --- a/docs/changes.rst +++ b/docs/changes.rst @@ -10,6 +10,12 @@ This change log is used to track all major changes to Mopidy. No description yet. +**Important changes** + +- If you use the Spotify backend, you need to upgrade to libspotify 0.0.6 and + the latest pyspotify from the Mopidy developers. Follow the instructions at + :ref:`/installation/libspotify/`. + **Changes** - Settings: @@ -31,6 +37,11 @@ No description yet. application menus. - Create infrastructure for creating Debian packages of Mopidy. +- Spotify backend: + + - Support high bitrate (320k). See + :attr:`mopidy.settings.SPOTIFY_HIGH_BITRATE` for details. + - Local backend: - Add :command:`mopidy-scan` command to generate ``tag_cache`` files without diff --git a/docs/installation/libspotify.rst b/docs/installation/libspotify.rst index b3ea06fa..9dc91066 100644 --- a/docs/installation/libspotify.rst +++ b/docs/installation/libspotify.rst @@ -5,7 +5,7 @@ libspotify installation Mopidy uses `libspotify `_ for playing music from the Spotify music service. To use :mod:`mopidy.backends.libspotify` you must -install libspotify and `pyspotify `_. +install libspotify and `pyspotify `_. .. warning:: @@ -22,14 +22,14 @@ install libspotify and `pyspotify `_. Installing libspotify on Linux ============================== -Download and install libspotify 0.0.4 for your OS and CPU architecture from +Download and install libspotify 0.0.6 for your OS and CPU architecture from https://developer.spotify.com/en/libspotify/. For 64-bit Linux the process is as follows:: - wget http://developer.spotify.com/download/libspotify/libspotify-0.0.4-linux6-x86_64.tar.gz - tar zxfv libspotify-0.0.4-linux6-x86_64.tar.gz - cd libspotify-0.0.4-linux6-x86_64/ + wget http://developer.spotify.com/download/libspotify/libspotify-0.0.6-linux6-x86_64.tar.gz + tar zxfv libspotify-0.0.6-linux6-x86_64.tar.gz + cd libspotify-0.0.6-linux6-x86_64/ sudo make install prefix=/usr/local sudo ldconfig @@ -46,6 +46,11 @@ libspotify:: brew install libspotify +To update your existing libspotify installation using Homebrew:: + + brew update + brew install `brew outdated` + When libspotify has been installed, continue with :ref:`pyspotify_installation`. @@ -69,7 +74,8 @@ In OS X no additional dependencies are needed. Check out the pyspotify code, and install it:: - git clone git://github.com/jodal/pyspotify.git + wget --no-check-certificate -O pyspotify.tar.gz https://github.com/mopidy/pyspotify/tarball/mopidy + tar zxfv pyspotify.tar.gz cd pyspotify/pyspotify/ sudo rm -rf build/ # If you are upgrading pyspotify sudo python setup.py install