Skip to content

Commit 7eff3e2

Browse files
committed
Fixing bug using is and not ==
1 parent 00f9fbd commit 7eff3e2

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

netmiko/base_connection.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -419,7 +419,7 @@ def _read_channel_timing(self, delay_factor=1, max_loops=150):
419419
# Default to making loop time be roughly equivalent to self.timeout (support old max_loops
420420
# and delay_factor arguments for backwards compatibility).
421421
delay_factor = self.select_delay_factor(delay_factor)
422-
if delay_factor == 1 and max_loops is 150:
422+
if delay_factor == 1 and max_loops == 150:
423423
max_loops = int(self.timeout / loop_delay)
424424

425425
channel_data = ""
@@ -914,7 +914,7 @@ def send_command(self, command_string, expect_string=None,
914914
# Default to making loop time be roughly equivalent to self.timeout (support old max_loops
915915
# and delay_factor arguments for backwards compatibility).
916916
delay_factor = self.select_delay_factor(delay_factor)
917-
if delay_factor == 1 and max_loops is 500:
917+
if delay_factor == 1 and max_loops == 500:
918918
# Default arguments are being used; use self.timeout instead
919919
max_loops = int(self.timeout / loop_delay)
920920

0 commit comments

Comments
 (0)