Better solution to overcome Connection reset by peer error in python telnet lib?
Question
> retry = range(3)
> for attempt in retry:
try:
> try:
> tn = telnetlib.Telnet(HOST)
> except exception as e:
> log error
>
> firing cmd
> break
except Exception as e:
> log error
> finally:
> telnet close
Is the best way or how many times i can retry in telnet lib.best way need.
No correct solution
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow