diff --git a/fakeredis-2.19.0-gh.tar.gz b/fakeredis-2.19.0-gh.tar.gz deleted file mode 100644 index 98f7bb6..0000000 --- a/fakeredis-2.19.0-gh.tar.gz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:429d27678bc70642c8d0428bf9a7651922e0edfda1b7e57bb6cd7a00135d3c96 -size 203837 diff --git a/fakeredis-2.23.4-gh.tar.gz b/fakeredis-2.23.4-gh.tar.gz new file mode 100644 index 0000000..ab24cd5 --- /dev/null +++ b/fakeredis-2.23.4-gh.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7c4f16e0d71d990c777bc157506fda38898f1775621cf5c100d24c099254e562 +size 209141 diff --git a/fix-tests.patch b/fix-tests.patch new file mode 100644 index 0000000..62acb97 --- /dev/null +++ b/fix-tests.patch @@ -0,0 +1,29 @@ +From b6c0140e17fb571906251e0fb300a52735427bf7 Mon Sep 17 00:00:00 2001 +From: Daniel M +Date: Fri, 27 Sep 2024 14:14:53 -0400 +Subject: [PATCH] fix:tests for redis 5.1.0 + +--- + test/test_asyncredis.py | 5 +-- + test/test_mixins/test_set_commands.py | 50 +++++++++++++++++---------- + 2 files changed, 35 insertions(+), 20 deletions(-) + +diff --git a/test/test_asyncredis.py b/test/test_asyncredis.py +index 9f623d38..c98bb515 100644 +--- a/test/test_asyncredis.py ++++ b/test/test_asyncredis.py +@@ -165,11 +165,12 @@ async def test_failed_script_error7(self, async_redis): + await async_redis.eval('return redis.call("ZCOUNT", KEYS[1])', 1, "foo") + + ++@fake_only + @testtools.run_test_if_redispy_ver("gte", "5.1") + async def test_repr_redis_51(async_redis: redis.asyncio.Redis): + assert re.fullmatch( +- r",db=0)>)>", ++ r",db=0\)>\)>", + repr(async_redis.connection_pool), + ) + diff --git a/python-fakeredis.changes b/python-fakeredis.changes index 50ae49f..f190899 100644 --- a/python-fakeredis.changes +++ b/python-fakeredis.changes @@ -1,3 +1,83 @@ +------------------------------------------------------------------- +Tue Oct 8 16:14:14 UTC 2024 - Markéta Machová + +- Add upstream fix-tests.patch + +------------------------------------------------------------------- +Wed Jul 31 02:16:56 UTC 2024 - Martin Schreiner + +- Update to 2.23.4. +- Changes from v2.23.4 + * fix:move random seed to HeavyKeeper to avoid issues. + * Documented how to use fakeredis with FastAPI. + * Using black for linting python code. +- Changes from v2.23.3 + * docs: Full code for FastAPI integration + * Fix ttl for empty stream +- Changes from v2.23.2 + * Fix reading multiple streams with blocking +- Changes from v2.23.1 + * Fix `XREAD` behavior when `COUNT` is not provided but `BLOCKING` + is provided +- Changes from v2.23.0 + * Support for TDigest commands: + `TDIGEST.ADD`,`TDIGEST.BYRANK`,`TDIGEST.BYREVRANK`,`TDIGEST.CDF`, + `TDIGEST.CREATE`, `TDIGEST.INFO`, `TDIGEST.MAX`, `TDIGEST.MERGE`, + `TDIGEST.MIN`, `TDIGEST.QUANTILE`, `TDIGEST.RANK`, + `TDIGEST.RESET`, `TDIGEST.REVRANK`, `TDIGEST.TRIMMED_MEAN`. + * Import `Self` from typing vs. typing_extension + * Update dependencies + * Add redis-py 5.0.4 to tests + * Update lupa version constraint +- Changes from v2.22.0 + * Support for setting LUA version from environment variable + `FAKEREDIS_LUA_VERSION` + * Support for loading LUA binary modules in fakeredis + * Fix the type hint for the version parameter in the async client + * Using LUA 5.1 like real redis + * fix: FakeRedisMixin.from_url() return type is really Self. +- Changes from v2.21.3 + * Revert behavior of defaulting to share the same server data + structure between connections + * Fix type hint for version +- Changes from v2.21.2 + * Connection params are defaulted to be the same between async and + sync connections + * `xinfo_stream` raises exception when stream does not exist +- Changes from v2.21.1 + * Support for float timeout values + * Fix django cache documentation +- Remove leftover dependency on python-packaging (solves rpmlint + warnings, too). +- Add new test and runtime dependency on 'typing_extensions' >= 4.7. +- No longer remove test file 'test/test_redis_asyncio.py'. + +------------------------------------------------------------------- +Sun Feb 4 10:08:59 UTC 2024 - Dirk Müller + +- update to 2.21.0: + * Implement all TOP-K commands (`TOPK.INFO`, `TOPK.LIST`, + `TOPK.RESERVE`, + * `TOPK.ADD`, `TOPK.COUNT`, `TOPK.QUERY`, `TOPK.INCRBY`) #278 + * Implement all cuckoo filter commands #276 + * Implement all Count-Min Sketch commands #277 + * Fix XREAD blocking bug #274 #275 + * EXAT option does not work #279 + +------------------------------------------------------------------- +Mon Dec 18 09:28:02 UTC 2023 - Dirk Müller + +- update to 2.20.1: + * Fix `XREAD` bug #256 + * Testing for python 3.12 + +------------------------------------------------------------------- +Mon Dec 4 21:41:12 UTC 2023 - Dirk Müller + +- update to 2.20.0: + * Implement `BITFIELD` command #247 + * Implement `COMMAND`, `COMMAND INFO`, `COMMAND COUNT` #248 + ------------------------------------------------------------------- Thu Oct 19 10:04:58 UTC 2023 - Matej Cepl diff --git a/python-fakeredis.spec b/python-fakeredis.spec index d57ea52..9a0acc6 100644 --- a/python-fakeredis.spec +++ b/python-fakeredis.spec @@ -1,7 +1,7 @@ # # spec file for package python-fakeredis # -# Copyright (c) 2023 SUSE LLC +# Copyright (c) 2024 SUSE LLC # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -18,30 +18,33 @@ %{?sle15_python_module_pythons} Name: python-fakeredis -Version: 2.19.0 +Version: 2.23.4 Release: 0 Summary: Fake implementation of redis API for testing purposes License: BSD-3-Clause AND MIT URL: https://github.com/cunla/fakeredis-py Source: https://github.com/cunla/fakeredis-py/archive/refs/tags/v%{version}.tar.gz#/fakeredis-%{version}-gh.tar.gz +# PATCH-FIX-UPSTREAM https://github.com/cunla/fakeredis-py/commit/b6c0140e17fb571906251e0fb300a52735427bf7 fix:tests for redis 5.1.0 +# there is a new version, but the update failed for me +Patch: fix-tests.patch BuildRequires: %{python_module base >= 3.7} BuildRequires: %{python_module pip} BuildRequires: %{python_module poetry-core} BuildRequires: fdupes BuildRequires: python-rpm-macros -Requires: python-packaging >= 23.1 Requires: python-redis >= 4 Requires: python-sortedcontainers >= 2.4.0 +Requires: python-typing_extensions >= 4.7 Suggests: python-lupa >= 1.14 BuildArch: noarch # SECTION test requirements -# technically requires hypothesis >= 6.56, but we don't have it yet -BuildRequires: %{python_module hypothesis} +BuildRequires: %{python_module hypothesis >= 6.56} BuildRequires: %{python_module pytest >= 7.1.2} BuildRequires: %{python_module pytest-asyncio >= 0.19.0} BuildRequires: %{python_module pytest-mock >= 3.7.0} BuildRequires: %{python_module redis >= 4} BuildRequires: %{python_module sortedcontainers >= 2.4.0} +BuildRequires: %{python_module typing_extensions >= 4.7} # /SECTION %python_subpackages @@ -60,7 +63,6 @@ Fake implementation of redis API for testing purposes. %check export LANG="en_US.UTF8" -rm -v test/test_redis_asyncio.py %pytest -m "not slow" %files %{python_files}