Skip to content

Commit 852de0e

Browse files
committed
Make black happy
1 parent 5d08b6a commit 852de0e

File tree

7 files changed

+12
-7
lines changed

7 files changed

+12
-7
lines changed

src/waitress/adjustments.py

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
#
1313
##############################################################################
1414
"""Adjustments are tunable parameters."""
15+
1516
import getopt
1617
import pkgutil
1718
import socket
@@ -356,13 +357,13 @@ def __init__(self, **kw):
356357
hp_pairs = []
357358
for i in self.listen:
358359
if ":" in i:
359-
(host, port) = i.rsplit(":", 1)
360+
host, port = i.rsplit(":", 1)
360361

361362
# IPv6 we need to make sure that we didn't split on the address
362363
if "]" in port: # pragma: nocover
363-
(host, port) = (i, str(self.port))
364+
host, port = (i, str(self.port))
364365
else:
365-
(host, port) = (i, str(self.port))
366+
host, port = (i, str(self.port))
366367

367368
if WIN: # pragma: no cover
368369
try:
@@ -389,7 +390,7 @@ def __init__(self, **kw):
389390
socket.IPPROTO_TCP,
390391
socket.AI_PASSIVE,
391392
):
392-
(family, socktype, proto, _, sockaddr) = s
393+
family, socktype, proto, _, sockaddr = s
393394

394395
# It seems that getaddrinfo() may sometimes happily return
395396
# the same result multiple times, this of course makes

src/waitress/buffers.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
#
1313
##############################################################################
1414
"""Buffers"""
15+
1516
from io import BytesIO
1617

1718
# copy_bytes controls the size of temp. strings for shuffling data around.

src/waitress/channel.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -376,7 +376,7 @@ def write_soon(self, data):
376376
self.total_outbufs_len += num_bytes
377377

378378
if self.total_outbufs_len >= self.adj.send_bytes:
379-
(flushed, exception) = self._flush_exception(
379+
flushed, exception = self._flush_exception(
380380
self._flush_some, do_close=False
381381
)
382382

@@ -396,7 +396,7 @@ def _flush_outbufs_below_high_watermark(self):
396396

397397
if self.total_outbufs_len > self.adj.outbuf_high_watermark:
398398
with self.outbuf_lock:
399-
(_, exception) = self._flush_exception(self._flush_some, do_close=False)
399+
_, exception = self._flush_exception(self._flush_some, do_close=False)
400400

401401
if exception:
402402
# An exception happened while flushing, wake up the main

src/waitress/parser.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@
1616
This server uses asyncore to accept connections and do initial
1717
processing but threads to do work.
1818
"""
19+
1920
from io import BytesIO
2021
import re
2122
from urllib import parse

src/waitress/server.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -360,7 +360,7 @@ def close(self):
360360

361361
class TcpWSGIServer(BaseWSGIServer):
362362
def bind_server_socket(self):
363-
(_, _, _, sockaddr) = self.sockinfo
363+
_, _, _, sockaddr = self.sockinfo
364364
self.bind(sockaddr)
365365

366366
def getsockname(self):

tests/test_parser.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
#
1313
##############################################################################
1414
"""HTTP Request Parser tests"""
15+
1516
import unittest
1617

1718
from waitress.adjustments import Adjustments

tests/test_regression.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
#
1313
##############################################################################
1414
"""Tests for waitress.channel maintenance logic"""
15+
1516
import doctest
1617

1718

0 commit comments

Comments
 (0)