Skip to content

Commit 84c861a

Browse files
committed
style: format locust/contrib/fasthttp.py (ruff)
1 parent a67aa8e commit 84c861a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

locust/contrib/fasthttp.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -325,7 +325,7 @@ def iter_lines(self, url: str, method: str = "GET", **kwargs) -> Generator[str]:
325325
for chunk in response.iter_content(chunk_size=1024, decode_content=True):
326326
# Ensure that chunk is a string.
327327
if isinstance(chunk, bytes):
328-
chunk = chunk.decode('utf-8', errors='replace')
328+
chunk = chunk.decode("utf-8", errors="replace")
329329

330330
buffer += chunk
331331
while "\n" in buffer:
@@ -601,7 +601,7 @@ def iter_content(self, chunk_size=1024, decode_content=True):
601601

602602
if decode_content and isinstance(chunk, bytes):
603603
try:
604-
chunk = chunk.decode('utf-8')
604+
chunk = chunk.decode("utf-8")
605605
except UnicodeDecodeError:
606606
# If decoding fails, preserve the data in byte format.
607607
pass

0 commit comments

Comments
 (0)