Skip to content

Commit 8a6c9f6

Browse files
Auto-format after feature commit
1 parent 50e472c commit 8a6c9f6

2 files changed

Lines changed: 3 additions & 10 deletions

File tree

src/dqliteclient/cluster.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -177,9 +177,7 @@ async def connect(
177177
enable debug logging to diagnose cluster churn instead of
178178
seeing only the final exception (ISSUE-78).
179179
"""
180-
attempts_cap = (
181-
max_attempts if max_attempts is not None else _DEFAULT_CONNECT_MAX_ATTEMPTS
182-
)
180+
attempts_cap = max_attempts if max_attempts is not None else _DEFAULT_CONNECT_MAX_ATTEMPTS
183181
if attempts_cap < 1:
184182
raise ValueError(f"max_attempts must be >= 1, got {attempts_cap}")
185183

src/dqliteclient/protocol.py

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -32,9 +32,7 @@
3232
_READ_CHUNK_SIZE = 4096
3333

3434

35-
def _validate_positive_int_or_none(
36-
value: int | None, name: str
37-
) -> int | None:
35+
def _validate_positive_int_or_none(value: int | None, name: str) -> int | None:
3836
"""Shared validation for positive-int-or-None parameters.
3937
4038
Used for both ``max_total_rows`` and ``max_continuation_frames``
@@ -278,10 +276,7 @@ async def _drain_continuations(
278276
raise ProtocolError(
279277
"ROWS continuation made no progress: frame had 0 rows and has_more=True"
280278
)
281-
if (
282-
self._max_continuation_frames is not None
283-
and frames > self._max_continuation_frames
284-
):
279+
if self._max_continuation_frames is not None and frames > self._max_continuation_frames:
285280
# Per-frame cap complements max_total_rows (ISSUE-98): a
286281
# slow-drip server sending 1-row-per-frame would
287282
# otherwise pin a client CPU with O(n) iterations of

0 commit comments

Comments
 (0)