napalm-automation-community / napalm-sros

NAPALM driver for Nokia SR OS
Apache License 2.0
17 stars 17 forks source link

Exception handling and changes in two methods #29

Closed ashah26 closed 3 years ago

ashah26 commented 3 years ago

1) added timeout for opening ssh connection 2) changed is_alive method logic to check both connections (netconf and ssh)

omron93 commented 3 years ago

@ashah26 It's kind of cosmetics note, but why all the print statements instead of using python logging functionality? napalm-sros is used as a library and that way it makes it harder to control from application how much logging goes from the library and it's not even possible to disable those messages if the application uses stdout for something else.

linx-riccardo commented 3 years ago

I agree with @omron93, python logging functionality should be used instead of print.