Skip to content

Commit f9b2136

Browse files
flake8: fix local variable unused cases
Fix several cases of F841 local variable is assigned to but never used. Part of #270
1 parent 5b8d967 commit f9b2136

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

tarantool/connection_pool.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -569,7 +569,8 @@ def _get_new_state(self, unit):
569569
try:
570570
read_only = resp.data[0]['ro']
571571
except (IndexError, KeyError) as exc:
572-
msg = f"Incorrect box.info response from {unit.addr['host']}:{unit.addr['port']}"
572+
msg = (f"Incorrect box.info response from {unit.addr['host']}:{unit.addr['port']}"
573+
f"reason: {repr(exc)}")
573574
warn(msg, PoolTolopogyWarning)
574575
return InstanceState(Status.UNHEALTHY)
575576

@@ -581,7 +582,8 @@ def _get_new_state(self, unit):
581582
warn(msg, PoolTolopogyWarning)
582583
return InstanceState(Status.UNHEALTHY)
583584
except (IndexError, KeyError) as exc:
584-
msg = f"Incorrect box.info response from {unit.addr['host']}:{unit.addr['port']}"
585+
msg = (f"Incorrect box.info response from {unit.addr['host']}:{unit.addr['port']}"
586+
f"reason: {repr(exc)}")
585587
warn(msg, PoolTolopogyWarning)
586588
return InstanceState(Status.UNHEALTHY)
587589

0 commit comments

Comments
 (0)