diff --git a/aioredis/connection.py b/aioredis/connection.py index 928671f04..067dcf204 100644 --- a/aioredis/connection.py +++ b/aioredis/connection.py @@ -1541,7 +1541,6 @@ def __init__( queue_class: Type[asyncio.Queue] = asyncio.LifoQueue, **connection_kwargs, ): - self.queue_class = queue_class self.timeout = timeout self._connections: List[Connection] diff --git a/docs/examples/getting_started/03_multiexec.py b/docs/examples/getting_started/03_multiexec.py index eb03ae4b5..5149a6a12 100644 --- a/docs/examples/getting_started/03_multiexec.py +++ b/docs/examples/getting_started/03_multiexec.py @@ -6,7 +6,7 @@ async def main(): redis = await aioredis.from_url("redis://localhost") async with redis.pipeline(transaction=True) as pipe: - ok1, ok2 = await (pipe.set("key1", "value1").set("key2", "value2").execute()) + ok1, ok2 = await pipe.set("key1", "value1").set("key2", "value2").execute() assert ok1 assert ok2 diff --git a/tests/conftest.py b/tests/conftest.py index 3beef2eb1..ba3fdb200 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -43,7 +43,6 @@ def __init__( help=None, metavar=None, ): - _option_strings = [] for option_string in option_strings: _option_strings.append(option_string) diff --git a/tests/test_lock.py b/tests/test_lock.py index d8f933695..57f40bc70 100644 --- a/tests/test_lock.py +++ b/tests/test_lock.py @@ -227,7 +227,6 @@ class TestLockClassSelection: def test_lock_class_argument(self, r): class MyLock: def __init__(self, *args, **kwargs): - pass lock = r.lock("foo", lock_class=MyLock) diff --git a/tests/test_pubsub.py b/tests/test_pubsub.py index 85c004659..8b7aef790 100644 --- a/tests/test_pubsub.py +++ b/tests/test_pubsub.py @@ -89,7 +89,6 @@ async def test_pattern_subscribe_unsubscribe(self, r): async def _test_resubscribe_on_reconnection( self, p, sub_type, unsub_type, sub_func, unsub_func, keys ): - for key in keys: assert await sub_func(key) is None @@ -131,7 +130,6 @@ async def test_resubscribe_to_patterns_on_reconnection(self, r): async def _test_subscribed_property( self, p, sub_type, unsub_type, sub_func, unsub_func, keys ): - assert p.subscribed is False await sub_func(keys[0]) # we're now subscribed even though we haven't processed the diff --git a/tests/test_sentinel.py b/tests/test_sentinel.py index 28d9f9f55..d775cd6ac 100644 --- a/tests/test_sentinel.py +++ b/tests/test_sentinel.py @@ -67,7 +67,6 @@ def client(self, host, port, **kwargs): @pytest.fixture() async def cluster(master_ip): - cluster = SentinelTestCluster(ip=master_ip) saved_Redis = aioredis.sentinel.Redis aioredis.sentinel.Redis = cluster.client