docs: Add docs on all available backends
This commit is contained in:
parent
cf1e5ff4ba
commit
8ddff80ce3
@ -30,3 +30,40 @@ Backend API
|
|||||||
:synopsis: Backend interface.
|
:synopsis: Backend interface.
|
||||||
:members:
|
:members:
|
||||||
:undoc-members:
|
:undoc-members:
|
||||||
|
|
||||||
|
|
||||||
|
Spotify backends
|
||||||
|
================
|
||||||
|
|
||||||
|
:mod:`mopidy.backends.despotify` -- Despotify backend
|
||||||
|
-----------------------------------------------------
|
||||||
|
|
||||||
|
.. automodule:: mopidy.backends.despotify
|
||||||
|
:synopsis: Spotify backend using the despotify library.
|
||||||
|
:members:
|
||||||
|
|
||||||
|
|
||||||
|
:mod:`mopidy.backends.libspotify` -- Libspotify backend
|
||||||
|
-------------------------------------------------------
|
||||||
|
|
||||||
|
.. automodule:: mopidy.backends.libspotify
|
||||||
|
:synopsis: Spotify backend using the libspotify library.
|
||||||
|
:members:
|
||||||
|
|
||||||
|
|
||||||
|
Other backends
|
||||||
|
==============
|
||||||
|
|
||||||
|
:mod:`mopidy.backends.dummy` -- Dummy backend
|
||||||
|
---------------------------------------------
|
||||||
|
|
||||||
|
.. automodule:: mopidy.backends.dummy
|
||||||
|
:synopsis: Dummy backend used for testing.
|
||||||
|
:members:
|
||||||
|
|
||||||
|
|
||||||
|
GStreamer backend
|
||||||
|
-----------------
|
||||||
|
|
||||||
|
``GstreamerBackend`` is pending merge from `adamcik/mopidy/gstreamer
|
||||||
|
<http://github.com/adamcik/mopidy/tree/gstreamer>`_.
|
||||||
|
|||||||
@ -31,40 +31,3 @@ not Mopidy.
|
|||||||
"spytify" -> "despotify" [ label="use C library" ]
|
"spytify" -> "despotify" [ label="use C library" ]
|
||||||
"DespotifyBackend" -> "AlsaMixer" [ label="use mixer API" ]
|
"DespotifyBackend" -> "AlsaMixer" [ label="use mixer API" ]
|
||||||
"AlsaMixer" -> "alsaaudio" [ label="use Python library" ]
|
"AlsaMixer" -> "alsaaudio" [ label="use Python library" ]
|
||||||
|
|
||||||
|
|
||||||
Notes on despotify/spytify
|
|
||||||
==========================
|
|
||||||
|
|
||||||
`spytify <http://despotify.svn.sourceforge.net/viewvc/despotify/src/bindings/python/>`_
|
|
||||||
is the Python bindings for the open source `despotify <http://despotify.se/>`_
|
|
||||||
library. It got no documentation to speak of, but a couple of examples are
|
|
||||||
available.
|
|
||||||
|
|
||||||
A list of the issues we currently experience with spytify, both bugs and
|
|
||||||
features we wished was there:
|
|
||||||
|
|
||||||
- r503: Sometimes segfaults when traversing stored playlists, their tracks,
|
|
||||||
artists, and albums. As it is not predictable, it may be a concurrency issue.
|
|
||||||
|
|
||||||
- r503: Segfaults when looking up playlists, both your own lists and other
|
|
||||||
peoples shared lists. To reproduce::
|
|
||||||
|
|
||||||
>>> import spytify
|
|
||||||
>>> s = spytify.Spytify('alice', 'secret')
|
|
||||||
>>> s.lookup('spotify:user:klette:playlist:5rOGYPwwKqbAcVX8bW4k5V')
|
|
||||||
Segmentation fault
|
|
||||||
|
|
||||||
|
|
||||||
Notes on libspotify/pyspotify
|
|
||||||
============================================
|
|
||||||
|
|
||||||
`pyspotify <http://github.com/winjer/pyspotify/>`_ is the Python bindings for
|
|
||||||
the official Spotify library, libspotify. It got no documentation to speak of,
|
|
||||||
but multiple examples are available. Like libspotify, pyspotify's calls are
|
|
||||||
mostly asynchronous.
|
|
||||||
|
|
||||||
A list of the issues we currently experience with pyspotify, both bugs and
|
|
||||||
features we wished was there:
|
|
||||||
|
|
||||||
- None at the moment.
|
|
||||||
|
|||||||
@ -14,6 +14,30 @@ logger = logging.getLogger(u'backends.despotify')
|
|||||||
ENCODING = 'utf-8'
|
ENCODING = 'utf-8'
|
||||||
|
|
||||||
class DespotifyBackend(BaseBackend):
|
class DespotifyBackend(BaseBackend):
|
||||||
|
"""
|
||||||
|
A Spotify backend which uses the open source `despotify library
|
||||||
|
<http://despotify.se/>`_.
|
||||||
|
|
||||||
|
`spytify <http://despotify.svn.sourceforge.net/viewvc/despotify/src/bindings/python/>`_
|
||||||
|
is the Python bindings for the despotify library. It got litle
|
||||||
|
documentation, but a couple of examples are available.
|
||||||
|
|
||||||
|
**Issues**
|
||||||
|
|
||||||
|
- r503: Sometimes segfaults when traversing stored playlists, their tracks,
|
||||||
|
artists, and albums. As it is not predictable, it may be a concurrency
|
||||||
|
issue.
|
||||||
|
|
||||||
|
- r503: Segfaults when looking up playlists, both your own lists and other
|
||||||
|
peoples shared lists. To reproduce::
|
||||||
|
|
||||||
|
>>> import spytify
|
||||||
|
>>> s = spytify.Spytify('alice', 'secret')
|
||||||
|
>>> s.lookup('spotify:user:klette:playlist:5rOGYPwwKqbAcVX8bW4k5V')
|
||||||
|
Segmentation fault
|
||||||
|
|
||||||
|
"""
|
||||||
|
|
||||||
def __init__(self, *args, **kwargs):
|
def __init__(self, *args, **kwargs):
|
||||||
super(DespotifyBackend, self).__init__(*args, **kwargs)
|
super(DespotifyBackend, self).__init__(*args, **kwargs)
|
||||||
self.current_playlist = DespotifyCurrentPlaylistController(backend=self)
|
self.current_playlist = DespotifyCurrentPlaylistController(backend=self)
|
||||||
|
|||||||
@ -4,6 +4,13 @@ from mopidy.backends import (BaseBackend, BaseCurrentPlaylistController,
|
|||||||
from mopidy.models import Playlist
|
from mopidy.models import Playlist
|
||||||
|
|
||||||
class DummyBackend(BaseBackend):
|
class DummyBackend(BaseBackend):
|
||||||
|
"""
|
||||||
|
A backend which implements the backend API in the simplest way possible.
|
||||||
|
Used in tests of the frontends.
|
||||||
|
|
||||||
|
Handles URIs starting with ``dummy:``.
|
||||||
|
"""
|
||||||
|
|
||||||
def __init__(self, *args, **kwargs):
|
def __init__(self, *args, **kwargs):
|
||||||
super(DummyBackend, self).__init__(*args, **kwargs)
|
super(DummyBackend, self).__init__(*args, **kwargs)
|
||||||
self.current_playlist = DummyCurrentPlaylistController(backend=self)
|
self.current_playlist = DummyCurrentPlaylistController(backend=self)
|
||||||
|
|||||||
@ -17,6 +17,24 @@ logger = logging.getLogger(u'backends.libspotify')
|
|||||||
ENCODING = 'utf-8'
|
ENCODING = 'utf-8'
|
||||||
|
|
||||||
class LibspotifyBackend(BaseBackend):
|
class LibspotifyBackend(BaseBackend):
|
||||||
|
"""
|
||||||
|
A Spotify backend which uses the official `libspotify library
|
||||||
|
<http://developer.spotify.com/en/libspotify/overview/>`_.
|
||||||
|
|
||||||
|
`pyspotify <http://github.com/winjer/pyspotify/>`_ is the Python bindings
|
||||||
|
for libspotify. It got no documentation, but multiple examples are
|
||||||
|
available. Like libspotify, pyspotify's calls are mostly asynchronous.
|
||||||
|
|
||||||
|
This backend should also work with `openspotify
|
||||||
|
<http://github.com/noahwilliamsson/openspotify>`_, but we haven't tested
|
||||||
|
that yet.
|
||||||
|
|
||||||
|
**Issues**
|
||||||
|
|
||||||
|
- libspotify is badly packaged. See
|
||||||
|
http://getsatisfaction.com/spotify/topics/libspotify_please_fix_the_installation_script.
|
||||||
|
"""
|
||||||
|
|
||||||
def __init__(self, *args, **kwargs):
|
def __init__(self, *args, **kwargs):
|
||||||
super(LibspotifyBackend, self).__init__(*args, **kwargs)
|
super(LibspotifyBackend, self).__init__(*args, **kwargs)
|
||||||
self.current_playlist = LibspotifyCurrentPlaylistController(
|
self.current_playlist = LibspotifyCurrentPlaylistController(
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user