summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTheo Massard <theo.massard@1000mercis.com>2018-06-26 14:30:29 +0200
committerTheo Massard <theo.massard@1000mercis.com>2018-06-26 14:30:29 +0200
commitad8dff243d572fc3316ef5ed0557f7b568b40b12 (patch)
tree59d238c1450aa4ef8425c8f3b6c83b8873ba396a
parente97f4b84b7b78a8931a40823823fad29c3db71d9 (diff)
downloadpython-memcached-ad8dff243d572fc3316ef5ed0557f7b568b40b12.tar.gz
minor flake8 errors
-rw-r--r--memcache.py5
-rw-r--r--setup.py3
2 files changed, 6 insertions, 2 deletions
diff --git a/memcache.py b/memcache.py
index c90af62..e0a2662 100644
--- a/memcache.py
+++ b/memcache.py
@@ -68,6 +68,8 @@ else:
def cmemcache_hash(key):
return (((binascii.crc32(key) & 0xffffffff) >> 16) & 0x7fff) or 1
+
+
serverHashFunction = cmemcache_hash
@@ -1443,7 +1445,8 @@ class _Host(object):
if self.socket:
recv = self.socket.recv
else:
- recv = lambda bufsize: b''
+ def recv(bufsize):
+ return b''
while True:
index = buf.find(b'\r\n')
diff --git a/setup.py b/setup.py
index 93cbe4d..b8a0d79 100644
--- a/setup.py
+++ b/setup.py
@@ -3,6 +3,7 @@
from setuptools.depends import get_module_constant
from setuptools import setup # noqa
+dl_url = "https://github.com/linsomniac/python-memcached/releases/download/{0}/python-memcached-{0}.tar.gz"
version = get_module_constant('memcache', '__version__')
setup(
@@ -15,7 +16,7 @@ setup(
maintainer="Sean Reifschneider",
maintainer_email="jafo@tummy.com",
url="https://github.com/linsomniac/python-memcached",
- download_url="https://github.com/linsomniac/python-memcached/releases/download/{0}/python-memcached-{0}.tar.gz".format(version),
+ download_url=dl_url.format(version),
py_modules=["memcache"],
install_requires=open('requirements.txt').read().split(),
classifiers=[