Mopidy-SomaFM-1.0.1/0000755000175000017500000000000012647755340016037 5ustar alexandrealexandre00000000000000Mopidy-SomaFM-1.0.1/setup.cfg0000644000175000017500000000023712647755340017662 0ustar alexandrealexandre00000000000000[flake8] application-import-names = mopidy_somafm,tests exclude = .git,.tox [wheel] universal = 1 [egg_info] tag_build = tag_date = 0 tag_svn_revision = 0 Mopidy-SomaFM-1.0.1/mopidy_somafm/0000755000175000017500000000000012647755340020702 5ustar alexandrealexandre00000000000000Mopidy-SomaFM-1.0.1/mopidy_somafm/ext.conf0000644000175000017500000000006612647755051022352 0ustar alexandrealexandre00000000000000[somafm] enabled = true encoding = mp3 quality = fast Mopidy-SomaFM-1.0.1/mopidy_somafm/__init__.py0000644000175000017500000000150112647755264023015 0ustar alexandrealexandre00000000000000from __future__ import unicode_literals import os from mopidy import config, ext __version__ = '1.0.1' class Extension(ext.Extension): dist_name = 'Mopidy-SomaFM' ext_name = 'somafm' version = __version__ def get_default_config(self): conf_file = os.path.join(os.path.dirname(__file__), 'ext.conf') return config.read(conf_file) def get_config_schema(self): schema = super(Extension, self).get_config_schema() schema['encoding'] = config.String(choices=('aac', 'mp3', 'aacp')) schema['quality'] = config.String( choices=('highest', 'fast', 'slow', 'firewall')) return schema def validate_environment(self): pass def setup(self, registry): from .actor import SomaFMBackend registry.add('backend', SomaFMBackend) Mopidy-SomaFM-1.0.1/mopidy_somafm/actor.py0000644000175000017500000000435312647755051022370 0ustar alexandrealexandre00000000000000from __future__ import unicode_literals import logging from mopidy import backend from mopidy.models import Album, Artist, Ref, Track import pykka import mopidy_somafm from .somafm import SomaFMClient logger = logging.getLogger(__name__) class SomaFMBackend(pykka.ThreadingActor, backend.Backend): def __init__(self, config, audio): super(SomaFMBackend, self).__init__() self.somafm = SomaFMClient( config['proxy'], "%s/%s" % ( mopidy_somafm.Extension.dist_name, mopidy_somafm.__version__)) self.library = SomaFMLibraryProvider(backend=self) self.uri_schemes = ['somafm'] self.quality = config['somafm']['quality'] self.encoding = config['somafm']['encoding'] def on_start(self): self.somafm.refresh(self.encoding, self.quality) class SomaFMLibraryProvider(backend.LibraryProvider): root_directory = Ref.directory(uri='somafm:root', name='Soma FM') def lookup(self, uri): # Whatever the uri, it will always contains one track # which is a url to a pls if not uri.startswith('somafm:'): return None channel_name = uri[uri.index('/') + 1:] channel_data = self.backend.somafm.channels[channel_name] # Artists artist = Artist(name=channel_data['dj']) # Build album (idem as playlist, but with more metada) album = Album( artists=[artist], date=channel_data['updated'], images=[channel_data['image']], name=channel_data['title'], uri='somafm:channel:/%s' % (channel_name)) track = Track( artists=[artist], album=album, genre=channel_data['genre'], name=channel_data['title'], uri=channel_data['pls']) return [track] def browse(self, uri): if uri != 'somafm:root': return [] result = [] for channel in self.backend.somafm.channels: result.append(Ref.track( uri='somafm:channel:/%s' % (channel), name=self.backend.somafm.channels[channel]['title'] )) result.sort(key=lambda ref: ref.name) return result Mopidy-SomaFM-1.0.1/mopidy_somafm/somafm.py0000644000175000017500000001041412647755051022535 0ustar alexandrealexandre00000000000000#!/usr/bin/env python2 # -*- coding: utf-8 -*- from __future__ import unicode_literals import logging import re import requests import urlparse from datetime import datetime try: import xml.etree.cElementTree as ET except ImportError: import xml.etree.ElementTree as ET from mopidy import httpclient logger = logging.getLogger(__name__) # # Channels are playlist and Album # PLS are tracks # PLS contents for internal use # class SomaFMClient(object): CHANNELS_URI = "https://api.somafm.com/channels.xml" channels = {} def __init__(self, proxy_config=None, user_agent=None): super(SomaFMClient, self).__init__() # Build requests session self.session = requests.Session() if proxy_config is not None: proxy = httpclient.format_proxy(proxy_config) self.session.proxies.update({'http': proxy, 'https': proxy}) full_user_agent = httpclient.format_user_agent(user_agent) self.session.headers.update({'user-agent': full_user_agent}) def refresh(self, encoding, quality): # clean previous data self.channels = {} # adjust quality real name plsquality = quality if plsquality != 'firewall': plsquality += 'pls' # download channels xml file channels_content = self._downloadContent(self.CHANNELS_URI) if channels_content is None: logger.error('Cannot fetch %s' % (self.CHANNELS_URI)) return # parse XML root = ET.fromstring(channels_content) for child_channel in root: pls_id = child_channel.attrib['id'] channel_data = {} for child_detail in child_channel: key = child_detail.tag val = child_detail.text if key in ['title', 'image', 'dj', 'genre']: channel_data[key] = val elif key == 'updated': channel_data['updated'] = datetime.fromtimestamp( int(val)).strftime("%Y-%m-%d") elif 'pls' in key: plsformat = child_detail.attrib['format'] if (key == plsquality and plsformat == encoding): channel_data['pls'] = val # firewall playlist are fastpls+mp3 but with fw path elif ( plsquality == 'firewall' and key == 'fastpls' and plsformat == 'mp3'): r1 = urlparse.urlsplit(val) channel_data['pls'] = "%s://%s/%s" % ( r1.scheme, r1.netloc, 'fw' + r1.path) if 'pls' in channel_data: self.channels[pls_id] = channel_data logger.info('Loaded %i SomaFM channels' % (len(self.channels))) def extractStreamUrlFromPls(self, pls_uri): pls_content = self._downloadContent(pls_uri) if pls_content is None: logger.error('Cannot fetch %s' % (pls_uri)) return pls_uri # try to find FileX= try: m = re.search( r"^(File\d)=(?P\S+)", pls_content, re.M) if m: return m.group("stream_url") else: return pls_uri except: return pls_uri def _downloadContent(self, url): try: r = self.session.get(url) logger.debug("Get %s : %i", url, r.status_code) if r.status_code is not 200: logger.error( "SomaFM: %s is not reachable [http code:%i]", url, r.status_code) return None except requests.exceptions.RequestException as e: logger.error("SomaFM RequestException: %s", e) except requests.exceptions.ConnectionError as e: logger.error("SomaFM ConnectionError: %s", e) except requests.exceptions.URLRequired as e: logger.error("SomaFM URLRequired: %s", e) except requests.exceptions.TooManyRedirects as e: logger.error("SomaFM TooManyRedirects: %s", e) except Exception as e: logger.error("SomaFM exception: %s", e) else: return r.text return None Mopidy-SomaFM-1.0.1/README.rst0000644000175000017500000000414712620205316017514 0ustar alexandrealexandre00000000000000************* Mopidy-SomaFM ************* .. image:: https://img.shields.io/pypi/v/Mopidy-SomaFM.svg?style=flat :target: https://pypi.python.org/pypi/Mopidy-SomaFM/ :alt: Latest PyPI version .. image:: https://img.shields.io/pypi/dm/Mopidy-SomaFM.svg?style=flat :target: https://pypi.python.org/pypi/Mopidy-SomaFM/ :alt: Number of PyPI downloads .. image:: https://img.shields.io/travis/AlexandrePTJ/mopidy-somafm/master.png?style=flat :target: https://travis-ci.org/AlexandrePTJ/mopidy-somafm :alt: Travis CI build status .. image:: https://img.shields.io/coveralls/AlexandrePTJ/mopidy-somafm/master.svg?style=flat :target: https://coveralls.io/r/AlexandrePTJ/mopidy-somafm?branch=master :alt: Test coverage `Mopidy `_ extension for playing music from `SomaFM `_. Installation ============ Install by running:: pip install Mopidy-SomaFM Or, if available, install the Debian/Ubuntu package from `apt.mopidy.com `_. Configuration ============= The extension requires that the Mopidy-Stream extension is enabled. It is bundled with Mopidy and enabled by default, so it will be available unless you've explicitly disabled it. You may change prefered quality and encoding in your Mopidy configuration file:: [somafm] encoding = aac quality = highest - ``encoding`` must be either ``aac``, ``mp3`` or ``aacp`` - ``quality`` must be one of ``highest``, ``fast``, ``slow``, ``firewall`` Warning ======= SomaFM does not provide every possible combination of ``encoding`` and ``quality``. For example, as of 2015/06/03, ``mp3 + highest`` gives only 3 playlists while ``aac + highest`` gives 15 and ``mp3 + fast`` gives 30. Some combinations are incompatible and will give zero playlist: ``aacp + highest`` and ``aac + fast``. Project resources ================= - `Source code `_ - `Issue tracker `_ - `Download development snapshot `_ Mopidy-SomaFM-1.0.1/MANIFEST.in0000644000175000017500000000030012647755051017565 0ustar alexandrealexandre00000000000000include .coveragerc include .travis.yml include LICENSE include MANIFEST.in include README.rst include CHANGES.rst include mopidy_somafm/ext.conf include tox.ini recursive-include tests *.py Mopidy-SomaFM-1.0.1/PKG-INFO0000644000175000017500000001235012647755340017135 0ustar alexandrealexandre00000000000000Metadata-Version: 1.1 Name: Mopidy-SomaFM Version: 1.0.1 Summary: SomaFM extension for Mopidy Home-page: http://github.com/AlexandrePTJ/mopidy-somafm/ Author: Alexandre Petitjean Author-email: alpetitjean@gmail.com License: MIT License Description: ************* Mopidy-SomaFM ************* .. image:: https://img.shields.io/pypi/v/Mopidy-SomaFM.svg?style=flat :target: https://pypi.python.org/pypi/Mopidy-SomaFM/ :alt: Latest PyPI version .. image:: https://img.shields.io/pypi/dm/Mopidy-SomaFM.svg?style=flat :target: https://pypi.python.org/pypi/Mopidy-SomaFM/ :alt: Number of PyPI downloads .. image:: https://img.shields.io/travis/AlexandrePTJ/mopidy-somafm/master.png?style=flat :target: https://travis-ci.org/AlexandrePTJ/mopidy-somafm :alt: Travis CI build status .. image:: https://img.shields.io/coveralls/AlexandrePTJ/mopidy-somafm/master.svg?style=flat :target: https://coveralls.io/r/AlexandrePTJ/mopidy-somafm?branch=master :alt: Test coverage `Mopidy `_ extension for playing music from `SomaFM `_. Installation ============ Install by running:: pip install Mopidy-SomaFM Or, if available, install the Debian/Ubuntu package from `apt.mopidy.com `_. Configuration ============= The extension requires that the Mopidy-Stream extension is enabled. It is bundled with Mopidy and enabled by default, so it will be available unless you've explicitly disabled it. You may change prefered quality and encoding in your Mopidy configuration file:: [somafm] encoding = aac quality = highest - ``encoding`` must be either ``aac``, ``mp3`` or ``aacp`` - ``quality`` must be one of ``highest``, ``fast``, ``slow``, ``firewall`` Warning ======= SomaFM does not provide every possible combination of ``encoding`` and ``quality``. For example, as of 2015/06/03, ``mp3 + highest`` gives only 3 playlists while ``aac + highest`` gives 15 and ``mp3 + fast`` gives 30. Some combinations are incompatible and will give zero playlist: ``aacp + highest`` and ``aac + fast``. Project resources ================= - `Source code `_ - `Issue tracker `_ - `Download development snapshot `_ Changelog ========= v1.0.1 (2016-01-19) ------------------- - Use httpclient helper from Mopidy >= 1.1 v0.8.0 (2015-11-09) ------------------- - #20: Replace HTTP with HTTPS for channels.xml v0.7.1 (2015-01-04) ------------------- - #11: Add Low Bitrate encoding (aacp) v0.7.0 (2014-07-29) ------------------- - #10: Remove playlists provider v0.6.0 (2014-03-15) ------------------- - Directly show PLS in browser - Add precision about 'quality' and 'encoding' couple v0.5.1 (2014-03-09) ------------------- - Fix doc typo v0.5.0 (2014-03-03) ------------------- - #5: Select prefered quality and format from config - Add tests and Travis-CI support v0.4.0 (2014-02-16) ------------------- - Add browse support for LibraryController v0.3.1 (2014-01-30) ------------------- - #3: Correct wrong subclassing v0.3.0 (2014-01-29) ------------------- - Require Mopidy >= 0.18 - Add proxy support for downloading SomaFM content - #1: handle 'requests' exceptions - Use builtin Mopidy's .pls support - Internal code cleanup v0.2.0 (2013-09-22) ------------------- - PLS files are downloaded to local temp directory - Implement library::lookup to allow adding tracks from playlist uri v0.1.1 (2013-09-14) ------------------- - Update Licence information v0.1.0 (2013-09-13) ------------------- - Initial release - Create SomaFM extension for Mopidy Platform: UNKNOWN Classifier: Environment :: No Input/Output (Daemon) Classifier: Intended Audience :: End Users/Desktop Classifier: License :: OSI Approved :: MIT License Classifier: Operating System :: OS Independent Classifier: Programming Language :: Python :: 2 Classifier: Topic :: Multimedia :: Sound/Audio :: Players Mopidy-SomaFM-1.0.1/setup.py0000644000175000017500000000247312647755051017556 0ustar alexandrealexandre00000000000000from __future__ import unicode_literals import re from setuptools import setup, find_packages def get_version(filename): content = open(filename).read() metadata = dict(re.findall("__([a-z]+)__ = '([^']+)'", content)) return metadata['version'] setup( name='Mopidy-SomaFM', version=get_version('mopidy_somafm/__init__.py'), url='http://github.com/AlexandrePTJ/mopidy-somafm/', license='MIT License', author='Alexandre Petitjean', author_email='alpetitjean@gmail.com', description='SomaFM extension for Mopidy', long_description="%s\n\n%s" % ( open('README.rst').read(), open('CHANGES.rst').read()), packages=find_packages(exclude=['tests', 'tests.*']), zip_safe=False, include_package_data=True, install_requires=[ 'setuptools', 'Mopidy >= 1.1', 'Pykka >= 1.1', 'requests >= 2.0.0' ], entry_points={ 'mopidy.ext': [ 'somafm = mopidy_somafm:Extension', ], }, classifiers=[ 'Environment :: No Input/Output (Daemon)', 'Intended Audience :: End Users/Desktop', 'License :: OSI Approved :: MIT License', 'Operating System :: OS Independent', 'Programming Language :: Python :: 2', 'Topic :: Multimedia :: Sound/Audio :: Players', ], ) Mopidy-SomaFM-1.0.1/tox.ini0000644000175000017500000000050512647755051017351 0ustar alexandrealexandre00000000000000[tox] envlist = py27, flake8 [testenv] sitepackages = true deps = mock pytest pytest-cov pytest-xdist commands = py.test \ --basetemp={envtmpdir} \ --cov=mopidy_somafm --cov-report=term-missing \ {posargs} [testenv:flake8] deps = flake8 skip_install = true commands = flake8 Mopidy-SomaFM-1.0.1/Mopidy_SomaFM.egg-info/0000755000175000017500000000000012647755340022174 5ustar alexandrealexandre00000000000000Mopidy-SomaFM-1.0.1/Mopidy_SomaFM.egg-info/dependency_links.txt0000644000175000017500000000000112647755340026242 0ustar alexandrealexandre00000000000000 Mopidy-SomaFM-1.0.1/Mopidy_SomaFM.egg-info/not-zip-safe0000644000175000017500000000000112300156477024412 0ustar alexandrealexandre00000000000000 Mopidy-SomaFM-1.0.1/Mopidy_SomaFM.egg-info/PKG-INFO0000644000175000017500000001235012647755340023272 0ustar alexandrealexandre00000000000000Metadata-Version: 1.1 Name: Mopidy-SomaFM Version: 1.0.1 Summary: SomaFM extension for Mopidy Home-page: http://github.com/AlexandrePTJ/mopidy-somafm/ Author: Alexandre Petitjean Author-email: alpetitjean@gmail.com License: MIT License Description: ************* Mopidy-SomaFM ************* .. image:: https://img.shields.io/pypi/v/Mopidy-SomaFM.svg?style=flat :target: https://pypi.python.org/pypi/Mopidy-SomaFM/ :alt: Latest PyPI version .. image:: https://img.shields.io/pypi/dm/Mopidy-SomaFM.svg?style=flat :target: https://pypi.python.org/pypi/Mopidy-SomaFM/ :alt: Number of PyPI downloads .. image:: https://img.shields.io/travis/AlexandrePTJ/mopidy-somafm/master.png?style=flat :target: https://travis-ci.org/AlexandrePTJ/mopidy-somafm :alt: Travis CI build status .. image:: https://img.shields.io/coveralls/AlexandrePTJ/mopidy-somafm/master.svg?style=flat :target: https://coveralls.io/r/AlexandrePTJ/mopidy-somafm?branch=master :alt: Test coverage `Mopidy `_ extension for playing music from `SomaFM `_. Installation ============ Install by running:: pip install Mopidy-SomaFM Or, if available, install the Debian/Ubuntu package from `apt.mopidy.com `_. Configuration ============= The extension requires that the Mopidy-Stream extension is enabled. It is bundled with Mopidy and enabled by default, so it will be available unless you've explicitly disabled it. You may change prefered quality and encoding in your Mopidy configuration file:: [somafm] encoding = aac quality = highest - ``encoding`` must be either ``aac``, ``mp3`` or ``aacp`` - ``quality`` must be one of ``highest``, ``fast``, ``slow``, ``firewall`` Warning ======= SomaFM does not provide every possible combination of ``encoding`` and ``quality``. For example, as of 2015/06/03, ``mp3 + highest`` gives only 3 playlists while ``aac + highest`` gives 15 and ``mp3 + fast`` gives 30. Some combinations are incompatible and will give zero playlist: ``aacp + highest`` and ``aac + fast``. Project resources ================= - `Source code `_ - `Issue tracker `_ - `Download development snapshot `_ Changelog ========= v1.0.1 (2016-01-19) ------------------- - Use httpclient helper from Mopidy >= 1.1 v0.8.0 (2015-11-09) ------------------- - #20: Replace HTTP with HTTPS for channels.xml v0.7.1 (2015-01-04) ------------------- - #11: Add Low Bitrate encoding (aacp) v0.7.0 (2014-07-29) ------------------- - #10: Remove playlists provider v0.6.0 (2014-03-15) ------------------- - Directly show PLS in browser - Add precision about 'quality' and 'encoding' couple v0.5.1 (2014-03-09) ------------------- - Fix doc typo v0.5.0 (2014-03-03) ------------------- - #5: Select prefered quality and format from config - Add tests and Travis-CI support v0.4.0 (2014-02-16) ------------------- - Add browse support for LibraryController v0.3.1 (2014-01-30) ------------------- - #3: Correct wrong subclassing v0.3.0 (2014-01-29) ------------------- - Require Mopidy >= 0.18 - Add proxy support for downloading SomaFM content - #1: handle 'requests' exceptions - Use builtin Mopidy's .pls support - Internal code cleanup v0.2.0 (2013-09-22) ------------------- - PLS files are downloaded to local temp directory - Implement library::lookup to allow adding tracks from playlist uri v0.1.1 (2013-09-14) ------------------- - Update Licence information v0.1.0 (2013-09-13) ------------------- - Initial release - Create SomaFM extension for Mopidy Platform: UNKNOWN Classifier: Environment :: No Input/Output (Daemon) Classifier: Intended Audience :: End Users/Desktop Classifier: License :: OSI Approved :: MIT License Classifier: Operating System :: OS Independent Classifier: Programming Language :: Python :: 2 Classifier: Topic :: Multimedia :: Sound/Audio :: Players Mopidy-SomaFM-1.0.1/Mopidy_SomaFM.egg-info/entry_points.txt0000644000175000017500000000005712647755340025474 0ustar alexandrealexandre00000000000000[mopidy.ext] somafm = mopidy_somafm:Extension Mopidy-SomaFM-1.0.1/Mopidy_SomaFM.egg-info/top_level.txt0000644000175000017500000000001612647755340024723 0ustar alexandrealexandre00000000000000mopidy_somafm Mopidy-SomaFM-1.0.1/Mopidy_SomaFM.egg-info/SOURCES.txt0000644000175000017500000000100012647755340024047 0ustar alexandrealexandre00000000000000.coveragerc .travis.yml CHANGES.rst LICENSE MANIFEST.in README.rst setup.cfg setup.py tox.ini Mopidy_SomaFM.egg-info/PKG-INFO Mopidy_SomaFM.egg-info/SOURCES.txt Mopidy_SomaFM.egg-info/dependency_links.txt Mopidy_SomaFM.egg-info/entry_points.txt Mopidy_SomaFM.egg-info/not-zip-safe Mopidy_SomaFM.egg-info/requires.txt Mopidy_SomaFM.egg-info/top_level.txt mopidy_somafm/__init__.py mopidy_somafm/actor.py mopidy_somafm/ext.conf mopidy_somafm/somafm.py tests/__init__.py tests/test_extension.py tests/test_somafm.pyMopidy-SomaFM-1.0.1/Mopidy_SomaFM.egg-info/requires.txt0000644000175000017500000000007012647755340024571 0ustar alexandrealexandre00000000000000setuptools Mopidy >= 1.1 Pykka >= 1.1 requests >= 2.0.0 Mopidy-SomaFM-1.0.1/tests/0000755000175000017500000000000012647755340017201 5ustar alexandrealexandre00000000000000Mopidy-SomaFM-1.0.1/tests/test_extension.py0000644000175000017500000000061612647755051022630 0ustar alexandrealexandre00000000000000from __future__ import unicode_literals from mopidy_somafm import Extension def test_get_default_config(): ext = Extension() config = ext.get_default_config() assert '[somafm]' in config assert 'enabled = true' in config def test_get_config_schema(): ext = Extension() schema = ext.get_config_schema() assert 'quality' in schema assert 'encoding' in schema Mopidy-SomaFM-1.0.1/tests/test_somafm.py0000644000175000017500000000265612647755051022104 0ustar alexandrealexandre00000000000000import unittest from mopidy_somafm.somafm import SomaFMClient class SomaFMClientTest(unittest.TestCase): def test_refresh(self): sfmc = SomaFMClient() sfmc.refresh('mp3', 'fast') self.assertIsNotNone(sfmc.channels) self.assertNotEqual(len(sfmc.channels), 0) def test_refresh_firewall(self): sfmc = SomaFMClient() sfmc.refresh('mp3', 'firewall') self.assertIsNotNone(sfmc.channels) self.assertNotEqual(len(sfmc.channels), 0) def test_refresh_no_channels(self): sfmc = SomaFMClient() sfmc.CHANNELS_URI = '' sfmc.refresh('mp3', 'fast') self.assertDictEqual(sfmc.channels, {}) self.assertEqual(len(sfmc.channels), 0) def test_downloadContent(self): url = "http://api.somafm.com/channels.xml" sfmc = SomaFMClient() data = sfmc._downloadContent(url) self.assertNotEqual(len(data), 0) def test_extractStreamUrlFromPls(self): url = "http://somafm.com/groovesalad.pls" sfmc = SomaFMClient() data = sfmc.extractStreamUrlFromPls(url) self.assertNotEqual(len(data), 0) self.assertNotEqual(data, url) def test_extractStreamUrlFromPls_unknown(self): url = "http://somafm.com/noneazerty.pls" sfmc = SomaFMClient() data = sfmc.extractStreamUrlFromPls(url) self.assertNotEqual(len(data), 0) self.assertEqual(data, url) Mopidy-SomaFM-1.0.1/tests/__init__.py0000644000175000017500000000000012452201461021260 0ustar alexandrealexandre00000000000000Mopidy-SomaFM-1.0.1/LICENSE0000644000175000017500000000207612647755051017050 0ustar alexandrealexandre00000000000000The MIT License (MIT) Copyright (c) 2016 Alexandre Petitjean Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. Mopidy-SomaFM-1.0.1/.coveragerc0000644000175000017500000000011612452201461020136 0ustar alexandrealexandre00000000000000[report] omit = */pyshared/* */python?.?/* */site-packages/nose/* Mopidy-SomaFM-1.0.1/CHANGES.rst0000644000175000017500000000254012647755051017641 0ustar alexandrealexandre00000000000000Changelog ========= v1.0.1 (2016-01-19) ------------------- - Use httpclient helper from Mopidy >= 1.1 v0.8.0 (2015-11-09) ------------------- - #20: Replace HTTP with HTTPS for channels.xml v0.7.1 (2015-01-04) ------------------- - #11: Add Low Bitrate encoding (aacp) v0.7.0 (2014-07-29) ------------------- - #10: Remove playlists provider v0.6.0 (2014-03-15) ------------------- - Directly show PLS in browser - Add precision about 'quality' and 'encoding' couple v0.5.1 (2014-03-09) ------------------- - Fix doc typo v0.5.0 (2014-03-03) ------------------- - #5: Select prefered quality and format from config - Add tests and Travis-CI support v0.4.0 (2014-02-16) ------------------- - Add browse support for LibraryController v0.3.1 (2014-01-30) ------------------- - #3: Correct wrong subclassing v0.3.0 (2014-01-29) ------------------- - Require Mopidy >= 0.18 - Add proxy support for downloading SomaFM content - #1: handle 'requests' exceptions - Use builtin Mopidy's .pls support - Internal code cleanup v0.2.0 (2013-09-22) ------------------- - PLS files are downloaded to local temp directory - Implement library::lookup to allow adding tracks from playlist uri v0.1.1 (2013-09-14) ------------------- - Update Licence information v0.1.0 (2013-09-13) ------------------- - Initial release - Create SomaFM extension for Mopidy Mopidy-SomaFM-1.0.1/.travis.yml0000644000175000017500000000077512647755051020160 0ustar alexandrealexandre00000000000000sudo: false language: python python: - "2.7_with_system_site_packages" addons: apt: sources: - mopidy-stable packages: - mopidy env: - TOX_ENV=py27 - TOX_ENV=flake8 install: - "pip install tox" script: - "tox -e $TOX_ENV" after_success: - "if [ $TOX_ENV == 'py27' ]; then pip install coveralls; coveralls; fi" notifications: email: recipients: - alpetitjean@gmail.com on_success: change on_failure: change use_notice: true skip_join: true