Skip to content

Commit 4961fd3

Browse files
committed
Lint fixes
1 parent c3c6485 commit 4961fd3

File tree

2 files changed

+7
-4
lines changed

2 files changed

+7
-4
lines changed

proxy/http/proxy/server.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -531,7 +531,8 @@ def connect_upstream(self) -> None:
531531
)
532532
except Exception as e: # TimeoutError, socket.gaierror
533533
logger.exception(
534-
'Unable to connect with upstream server', exc_info=e)
534+
'Unable to connect with upstream server', exc_info=e,
535+
)
535536
self.server.closed = True
536537
raise ProxyConnectionFailed(text_(host), port, repr(e)) from e
537538
else:

proxy/plugin/cloudflare_dns.py

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -54,14 +54,16 @@ def resolve_dns(self, host: str, port: int) -> Tuple[Optional[str], Optional[Tup
5454
# TODO: Support resolution via Authority (SOA) to add support for
5555
# AAAA (IPv6) query
5656
r = httpx.get(
57-
"https://{0}.cloudflare-dns.com/dns-query?name={1}&type=A".format(
58-
self.flags.cloudflare_dns_mode, host),
57+
'https://{0}.cloudflare-dns.com/dns-query?name={1}&type=A'.format(
58+
self.flags.cloudflare_dns_mode, host,
59+
),
5960
headers={'accept': 'application/dns-json'},
6061
verify=context,
6162
timeout=httpx.Timeout(timeout=5.0),
6263
proxies={
6364
'all://': None,
64-
})
65+
},
66+
)
6567
if r.status_code != 200:
6668
return None, None
6769
response = r.json()

0 commit comments

Comments
 (0)