python-redis
Port variant py37
Summary Python client for Redis key-value store (PY37)
Package version 3.5.3
Homepage https://github.com/andymccurdy/redis-py
Keywords python
Maintainer Python Automaton
License Not yet specified
Other variants py38
Ravenports Buildsheet | History
Ravensource Port Directory | History
Last modified 02 JUN 2020, 02:58:10 UTC
Port created 28 AUG 2018, 14:25:25 UTC
Subpackage Descriptions
single redis-py ======== The Python interface to the Redis key-value store. Python 2 Compatibility Note --------------------------- redis-py 3.5.x will be the last version of redis-py that supports Python 2. The 3.5.x line will continue to get bug fixes and security patches that support Python 2 until August 1, 2020. redis-py 4.0 will be the next major version and will require Python 3.5+. Installation ------------ redis-py requires a running Redis server. See [Redis's quickstart ] for installation instructions. redis-py can be installed using `pip` similar to other Python packages. Do not use `sudo` with `pip`. It is usually good to work in a [virtualenv] or [venv] to avoid conflicts with other package managers and Python projects. For a quick introduction see [Python Virtual Environments in Five Minutes]. To install redis-py, simply: .. code-block:: bash $ pip install redis or from source: .. code-block:: bash $ python setup.py install Getting Started --------------- .. code-block:: pycon >>> import redis >>> r = redis.Redis(host='localhost', port=6379, db=0) >>> r.set('foo', 'bar') True >>> r.get('foo') b'bar' By default, all responses are returned as `bytes` in Python 3 and `str` in Python 2. The user is responsible for decoding to Python 3 strings or Python 2 unicode objects. If **all** string responses from a client should be decoded, the user can specify `decode_responses=True` to `Redis.__init__`. In this case, any Redis command that returns a string type will be decoded with the `encoding` specified. Upgrading from redis-py 2.X to 3.0 ---------------------------------- redis-py 3.0 introduces many new features but required a number of backwards incompatible changes to be made in the process. This section attempts to provide an upgrade path for users migrating from 2.X to 3.0. Python Version Support ^^^^^^^^^^^^^^^^^^^^^^ redis-py 3.0 supports Python 2.7 and Python 3.5+. Client Classes: Redis and StrictRedis ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ redis-py 3.0 drops support for the legacy "Redis" client class. "StrictRedis" has been renamed to "Redis" and an alias named "StrictRedis" is provided so that users previously using "StrictRedis" can continue to run unchanged. The 2.X "Redis" class provided alternative implementations of a few commands. This confused users (rightfully so) and caused a number of support issues. To make things easier going forward, it was decided to drop support for these alternate implementations and instead focus on a single client class. 2.X users that are already using StrictRedis don't have to change the class name. StrictRedis will continue to work for the foreseeable future. 2.X users that are using the Redis class will have to make changes if they use any of the following commands: * SETEX: The argument order has changed. The new order is (name, time, value). * LREM: The argument order has changed. The new order is (name, num, value).
Configuration Switches (platform-specific settings discarded)
PY37 ON Build using Python 3.7 PY38 OFF Build using Python 3.8
Package Dependencies by Type
Build and Runtime python37:single:standard
python-setuptools:single:py37
Download groups
main mirror://PYPI/r/redis
Distribution File Information
0e7e0cfca8660dea8b7d5cd8c4f6c5e29e11f31158c0b0ae91a397f00e5a05a2 141112 redis-3.5.3.tar.gz
Ports that require python-redis:py37
No other ports depend on this one.