Skip to content

Commit 00ff8bf

Browse files
committed
Fix lint errors
1 parent 210f59b commit 00ff8bf

4 files changed

Lines changed: 24 additions & 6 deletions

File tree

pubnub/request_handlers/async_aiohttp.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -179,7 +179,10 @@ async def async_request(self, options_func, cancellation_event):
179179
data = "N/A"
180180

181181
logger.debug(data)
182-
logger.debug("PubNub request completed: operation=%s protocol=%s" % (options.operation_type, response_info.http_version))
182+
logger.debug(
183+
"PubNub request completed: operation=%s protocol=%s"
184+
% (options.operation_type, response_info.http_version)
185+
)
183186

184187
if response.status not in (200, 307, 204):
185188

pubnub/request_handlers/async_httpx.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -189,7 +189,10 @@ async def async_request(self, options_func, cancellation_event):
189189
data = "N/A"
190190

191191
logger.debug(data)
192-
logger.debug("PubNub request completed: operation=%s protocol=%s" % (options.operation_type, response_info.http_version))
192+
logger.debug(
193+
"PubNub request completed: operation=%s protocol=%s"
194+
% (options.operation_type, response_info.http_version)
195+
)
193196

194197
if response.status_code not in (200, 307, 204):
195198

pubnub/request_handlers/httpx.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -267,7 +267,10 @@ def _invoke_request(self, p_options, e_options, base_origin):
267267

268268
try:
269269
res = self.session.request(**args)
270-
logger.debug("PubNub request completed: operation=%s protocol=%s" % (e_options.operation_type, res.http_version))
270+
logger.debug(
271+
"PubNub request completed: operation=%s protocol=%s"
272+
% (e_options.operation_type, res.http_version)
273+
)
271274

272275
# Safely access response text - read content first for streaming responses
273276
try:

pubnub/request_handlers/requests.py

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -175,7 +175,10 @@ def _build_envelope(self, p_options, e_options):
175175
uuid=uuid,
176176
auth_key=auth_key,
177177
client_request=res.request,
178-
http_version=f"HTTP/{res.raw.version // 10}.{res.raw.version % 10}" if res.raw and res.raw.version else None
178+
http_version=(
179+
f"HTTP/{res.raw.version // 10}.{res.raw.version % 10}"
180+
if res.raw and res.raw.version else None
181+
)
179182
)
180183

181184
if not res.ok:
@@ -271,8 +274,14 @@ def _invoke_request(self, p_options, e_options, base_origin):
271274
res = self.session.request(**args)
272275
logger.debug("GOT %s" % res.text)
273276

274-
http_ver = f"HTTP/{res.raw.version // 10}.{res.raw.version % 10}" if res.raw and res.raw.version else "unknown"
275-
logger.debug("PubNub request completed: operation=%s protocol=%s" % (e_options.operation_type, http_ver))
277+
http_ver = (
278+
f"HTTP/{res.raw.version // 10}.{res.raw.version % 10}"
279+
if res.raw and res.raw.version else "unknown"
280+
)
281+
logger.debug(
282+
"PubNub request completed: operation=%s protocol=%s"
283+
% (e_options.operation_type, http_ver)
284+
)
276285

277286
except requests.exceptions.ConnectionError as e:
278287
raise PubNubException(

0 commit comments

Comments
 (0)