From 8dc340156c6119a71425d610368b67ae2300273a Mon Sep 17 00:00:00 2001 From: Raj Shah Date: Thu, 10 Dec 2020 21:01:26 -0800 Subject: [PATCH 1/2] Fix ._scan() bug in RedisCounter._make_counter() Previously, we were calling `._scan()` multiple times, and using only every other `._scan()` call's results, and never using `encoded_dict`. Now, we're using `encoded_dict` and not skippinng over every other `._scan()` call. --- pottery/counter.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pottery/counter.py b/pottery/counter.py index 1ad43e4c..33e633b7 100644 --- a/pottery/counter.py +++ b/pottery/counter.py @@ -100,7 +100,7 @@ def _make_counter(self) -> Counter[JSONTypes]: cursor, encoded_dict = self._scan(cursor=cursor) decoded_dict = { self._decode(key): self._decode(value) - for key, value in self._scan()[1].items() + for key, value in encoded_dict.items() } counter.update(decoded_dict) if cursor == 0: # pragma: no cover From 49944068b2705a7424a4e4d9a7f09ad7df0db999 Mon Sep 17 00:00:00 2001 From: Raj Shah Date: Thu, 10 Dec 2020 21:11:48 -0800 Subject: [PATCH 2/2] Bump version number --- pottery/__init__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pottery/__init__.py b/pottery/__init__.py index 83482783..96483465 100644 --- a/pottery/__init__.py +++ b/pottery/__init__.py @@ -13,7 +13,7 @@ __title__ = 'pottery' -__version__ = '1.0.7' +__version__ = '1.0.8' __description__, __long_description__ = ( s.strip() for s in __doc__.split(sep='\n\n', maxsplit=1) )