diff --git a/mopidy/stream/actor.py b/mopidy/stream/actor.py index b42985d0..ff99264d 100644 --- a/mopidy/stream/actor.py +++ b/mopidy/stream/actor.py @@ -74,6 +74,13 @@ class StreamLibraryProvider(backend.LibraryProvider): class StreamPlaybackProvider(backend.PlaybackProvider): def translate_uri(self, uri): + if urllib.parse.urlsplit(uri).scheme not in self.backend.uri_schemes: + return None + + if self.backend._blacklist_re.match(uri): + logger.debug('URI matched metadata lookup blacklist: %s', uri) + return uri + return _unwrap_stream( uri, timeout=self.backend._timeout, diff --git a/tests/stream/test_playback.py b/tests/stream/test_playback.py index 4ff684ca..1816f73e 100644 --- a/tests/stream/test_playback.py +++ b/tests/stream/test_playback.py @@ -30,7 +30,7 @@ def config(): 'stream': { 'timeout': TIMEOUT, 'metadata_blacklist': [], - 'protocols': ['file'], + 'protocols': ['http'], }, 'file': { 'enabled': False