Merge pull request #289 from pylast/rm-2-3.4

Drop support for legacy Python 3.4
This commit is contained in:
Hugo 2018-12-30 00:18:54 +02:00 committed by GitHub
commit 718fba04b8
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 14 additions and 17 deletions

View file

@ -25,8 +25,6 @@ matrix:
env: TOXENV=py36
- python: 3.5
env: TOXENV=py35
- python: 3.4
env: TOXENV=py34
- python: pypy3
env: TOXENV=pypy3
- python: 3.8-dev

View file

@ -18,7 +18,7 @@ Installation
Install via pip:
pip install pylast
Install latest development version:
pip install -U git+https://github.com/pylast/pylast.git
@ -29,7 +29,7 @@ Or from requirements.txt:
Note:
* pylast 3.0.0+ supports Python 3.4+ ([#265](https://github.com/pylast/pylast/issues/265))
* pylast 3.0.0+ supports Python 3.5+ ([#265](https://github.com/pylast/pylast/issues/265))
* pyLast 2.2.0 - 2.4.0 supports Python 2.7.10+, 3.4, 3.5, 3.6, 3.7.
* pyLast 2.0.0 - 2.1.0 supports Python 2.7.10+, 3.4, 3.5, 3.6.
* pyLast 1.7.0 - 1.9.0 supports Python 2.7, 3.3, 3.4, 3.5, 3.6.

View file

@ -138,7 +138,7 @@ logger = logging.getLogger(__name__)
logging.getLogger(__name__).addHandler(logging.NullHandler())
class _Network(object):
class _Network:
"""
A music social network website such as Last.fm or
one with a Last.fm-compatible API.
@ -795,7 +795,7 @@ class LibreFMNetwork(_Network):
)
class _ShelfCacheBackend(object):
class _ShelfCacheBackend:
"""Used as a backend for caching cacheable requests."""
def __init__(self, file_path=None):
@ -816,7 +816,7 @@ class _ShelfCacheBackend(object):
self.shelf[key] = xml_string
class _Request(object):
class _Request:
"""Representing an abstract web service operation."""
def __init__(self, network, method_name, params=None):
@ -981,7 +981,7 @@ class _Request(object):
raise WSError(self.network, status, details)
class SessionKeyGenerator(object):
class SessionKeyGenerator:
"""Methods of generating a session key:
1) Web Authentication:
a. network = get_*_network(API_KEY, API_SECRET)
@ -1104,7 +1104,7 @@ def _string_output(func):
return r
class _BaseObject(object):
class _BaseObject:
"""An abstract webservices object."""
network = None
@ -1193,7 +1193,7 @@ class _BaseObject(object):
return _extract(node, section)
class _Chartable(object):
class _Chartable:
"""Common functions for classes with charts."""
def __init__(self, ws_prefix):
@ -1264,7 +1264,7 @@ class _Chartable(object):
return seq
class _Taggable(object):
class _Taggable:
"""Common functions for classes with tags."""
def __init__(self, ws_prefix):
@ -1593,7 +1593,7 @@ class Album(_Opus):
__hash__ = _Opus.__hash__
def __init__(self, artist, title, network, username=None, info=None):
super(Album, self).__init__(artist, title, network, "album", username, info)
super().__init__(artist, title, network, "album", username, info)
def get_tracks(self):
"""Returns the list of Tracks on this album."""
@ -2062,7 +2062,7 @@ class Track(_Opus):
__hash__ = _Opus.__hash__
def __init__(self, artist, title, network, username=None, info=None):
super(Track, self).__init__(artist, title, network, "track", username, info)
super().__init__(artist, title, network, "track", username, info)
def get_correction(self):
"""Returns the corrected track name."""

View file

@ -10,7 +10,7 @@ with open("pylast/version.py") as f:
version = version_dict["__version__"]
if sys.version_info < (3, 4):
if sys.version_info < (3, 5):
error = """pylast 3.0 and above are no longer compatible with Python 2.
This is pylast {} and you are using Python {}.
@ -64,7 +64,6 @@ setup(
"Topic :: Multimedia :: Sound/Audio",
"Topic :: Software Development :: Libraries :: Python Modules",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.4",
"Programming Language :: Python :: 3.5",
"Programming Language :: Python :: 3.6",
"Programming Language :: Python :: 3.7",
@ -72,7 +71,7 @@ setup(
"Programming Language :: Python :: Implementation :: CPython",
"Programming Language :: Python :: Implementation :: PyPy",
],
python_requires=">=3.4",
python_requires=">=3.5",
keywords=["Last.fm", "music", "scrobble", "scrobbling"],
packages=find_packages(exclude=("tests*",)),
license="Apache2",

View file

@ -1,5 +1,5 @@
[tox]
envlist = py37, py36, py35, py34, pypy3, py38dev
envlist = py37, py36, py35, pypy3, py38dev
recreate = False
[testenv]