Feb-08-2019, 04:56 PM
(This post was last modified: Feb-08-2019, 05:13 PM by Prarthana_12.)
I am using netmiko on my ubuntu 12.04 to SSH into one of my router. I am able to successfully SSH into the router, however along with my output I get below warning/error -
john@lab:~$ sudo python t3.py
/usr/local/lib/python2.7/dist-packages/cryptography/hazmat/primitives/constant_time.py:26: CryptographyDeprecationWarning: Support for your Python version is deprecated. The next version of cryptography will remove support. Please upgrade to a 2.7.x release that supports hmac.compare_digest as soon as possible.
utils.DeprecatedIn23,
Interface IP-Address OK? Method Status Protocol
FastEthernet0/0 unassigned YES manual administratively down down
FastEthernet1/0 198.51.100.5 YES manual up up
I know that I have to update to new Linux OS version, however, can someone help me on how I can just store this warning/error and not let it interfere with my output.
I did try using the warning module, but no luck-
with warnings.catch_warnings():
warnings.simplefilter("ignore")
warnings.warn("deprecated", DeprecationWarning)
john@lab:~$ sudo python t3.py
/usr/local/lib/python2.7/dist-packages/cryptography/hazmat/primitives/constant_time.py:26: CryptographyDeprecationWarning: Support for your Python version is deprecated. The next version of cryptography will remove support. Please upgrade to a 2.7.x release that supports hmac.compare_digest as soon as possible.
utils.DeprecatedIn23,
Interface IP-Address OK? Method Status Protocol
FastEthernet0/0 unassigned YES manual administratively down down
FastEthernet1/0 198.51.100.5 YES manual up up
I know that I have to update to new Linux OS version, however, can someone help me on how I can just store this warning/error and not let it interfere with my output.
I did try using the warning module, but no luck-
with warnings.catch_warnings():
warnings.simplefilter("ignore")
warnings.warn("deprecated", DeprecationWarning)