Skip to content

Commit 8cd959e

Browse files
committed
[GROW-3247] fix style issue
1 parent cc9ad30 commit 8cd959e

File tree

2 files changed

+7
-3
lines changed

2 files changed

+7
-3
lines changed

redis/cluster.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2038,7 +2038,9 @@ def _send_cluster_commands(
20382038
for n in nodes.values():
20392039
n.connection_pool.release(n.connection)
20402040
nodes = {}
2041-
if self.retry and isinstance(e, self.retry._supported_errors):
2041+
if self.retry and isinstance(
2042+
e, self.retry._supported_errors
2043+
):
20422044
backoff = self.retry._backoff.compute(attempts_count)
20432045
if backoff > 0:
20442046
time.sleep(backoff)

tests/test_cluster.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2792,9 +2792,11 @@ class TestClusterPipeline:
27922792
"""
27932793

27942794
@pytest.mark.parametrize("function", ["write", "read"])
2795-
def test_connection_release_with_unexpected_error_in_node_commands(self, r, function):
2795+
def test_connection_release_with_unexpected_error_in_node_commands(
2796+
self, r, function
2797+
):
27962798
"""
2797-
Test that connection is released to the pool, even with unexpected error in NodeCommands' functions
2799+
Test that connection is released to the pool, even with an unexpected error
27982800
"""
27992801
with patch.object(NodeCommands, function) as m:
28002802

0 commit comments

Comments
 (0)