Merge branch 'release/0.1.1' into develop
Conflicts: docs/changes.rst
This commit is contained in:
commit
abe54aacb0
@ -27,11 +27,23 @@ No description yet.
|
||||
:attr:`mopidy.settings.DEBUG_LOG_FILENAME`.
|
||||
- Switched from using subprocesses to threads. This partly fixes the OS X
|
||||
support. See :issue:`14` for details.
|
||||
- MPD frontend:
|
||||
- MPD frontend: ``list`` now supports queries by artist, album name, and date,
|
||||
as used by e.g. the Ario client. (Fixes: :issue:`20`)
|
||||
|
||||
- ``add ""`` and ``addid ""`` now behaves as expected.
|
||||
- ``list`` now supports queries by artist, album name, and date, as used by
|
||||
e.g. the Ario client. (Fixes: :issue:`20`)
|
||||
|
||||
0.1.1 (in development)
|
||||
======================
|
||||
|
||||
No description yet.
|
||||
|
||||
**Changes**
|
||||
|
||||
- MPD frontend: ``add ""`` and ``addid ""`` now behaves as expected. (Fixes
|
||||
:issue:`16`)
|
||||
- Fix wrong behavior on end of track and next after random mode has been used.
|
||||
(Fixes: :issue:`18`)
|
||||
- Fix infinite recursion loop crash on playback of non-playable tracks when in
|
||||
random mode. (Fixes :issue:`17`)
|
||||
|
||||
|
||||
0.1.0 (2010-08-23)
|
||||
|
||||
@ -389,6 +389,9 @@ class BasePlaybackController(object):
|
||||
self.current_cp_track = cp_track
|
||||
self.state = self.PLAYING
|
||||
if not self._play(cp_track[1]):
|
||||
# Track is not playable
|
||||
if self.random and self._shuffled:
|
||||
self._shuffled.remove(cp_track)
|
||||
if on_error_step == 1:
|
||||
self.next()
|
||||
elif on_error_step == -1:
|
||||
|
||||
@ -44,16 +44,19 @@ class DummyLibraryController(BaseLibraryController):
|
||||
|
||||
class DummyPlaybackController(BasePlaybackController):
|
||||
def _next(self, track):
|
||||
return True
|
||||
"""Pass None as track to force failure"""
|
||||
return track is not None
|
||||
|
||||
def _pause(self):
|
||||
return True
|
||||
|
||||
def _play(self, track):
|
||||
return True
|
||||
"""Pass None as track to force failure"""
|
||||
return track is not None
|
||||
|
||||
def _previous(self, track):
|
||||
return True
|
||||
"""Pass None as track to force failure"""
|
||||
return track is not None
|
||||
|
||||
def _resume(self):
|
||||
return True
|
||||
|
||||
@ -24,6 +24,9 @@ class MpdServer(asyncore.dispatcher):
|
||||
try:
|
||||
if socket.has_ipv6:
|
||||
self.create_socket(socket.AF_INET6, socket.SOCK_STREAM)
|
||||
# Explicitly configure socket to work for both IPv4 and IPv6
|
||||
self.socket.setsockopt(
|
||||
socket.IPPROTO_IPV6, socket.IPV6_V6ONLY, 0)
|
||||
else:
|
||||
self.create_socket(socket.AF_INET, socket.SOCK_STREAM)
|
||||
self.set_reuse_addr()
|
||||
|
||||
@ -6,6 +6,40 @@ from mopidy.frontends.mpd import dispatcher
|
||||
from mopidy.mixers.dummy import DummyMixer
|
||||
from mopidy.models import Track
|
||||
|
||||
class IssueGH17RegressionTest(unittest.TestCase):
|
||||
"""
|
||||
The issue: http://github.com/jodal/mopidy/issues#issue/17
|
||||
|
||||
How to reproduce:
|
||||
|
||||
- Play a playlist where one track cannot be played
|
||||
- Turn on random mode
|
||||
- Press next until you get to the unplayable track
|
||||
"""
|
||||
|
||||
def setUp(self):
|
||||
self.backend = DummyBackend(mixer_class=DummyMixer)
|
||||
self.backend.current_playlist.append([
|
||||
Track(uri='a'), Track(uri='b'), None,
|
||||
Track(uri='d'), Track(uri='e'), Track(uri='f')])
|
||||
self.mpd = dispatcher.MpdDispatcher(backend=self.backend)
|
||||
|
||||
def test(self):
|
||||
random.seed(1) # Playlist order: abcfde
|
||||
self.mpd.handle_request(u'play')
|
||||
self.assertEquals('a', self.backend.playback.current_track.uri)
|
||||
self.mpd.handle_request(u'random "1"')
|
||||
self.mpd.handle_request(u'next')
|
||||
self.assertEquals('b', self.backend.playback.current_track.uri)
|
||||
self.mpd.handle_request(u'next')
|
||||
# Should now be at track 'c', but playback fails and it skips ahead
|
||||
self.assertEquals('f', self.backend.playback.current_track.uri)
|
||||
self.mpd.handle_request(u'next')
|
||||
self.assertEquals('d', self.backend.playback.current_track.uri)
|
||||
self.mpd.handle_request(u'next')
|
||||
self.assertEquals('e', self.backend.playback.current_track.uri)
|
||||
|
||||
|
||||
class IssueGH18RegressionTest(unittest.TestCase):
|
||||
"""
|
||||
The issue: http://github.com/jodal/mopidy/issues#issue/18
|
||||
|
||||
Loading…
Reference in New Issue
Block a user