improve text when ipaddress module is missing (#7043)

This commit is contained in:
Tony Murray
2017-07-17 13:00:58 -05:00
committed by Neil Lathwood
parent fabf0c54f4
commit fb121923b0

View File

@@ -37,7 +37,9 @@ from time import time
try:
from ipaddress import ip_network, ip_address
except:
print('Could not import ipaddress module. Please install python2-ipaddress.')
print('Could not import ipaddress module. Please install python-ipaddress or use python3 to run this script')
print('Debian/Ubuntu: apt install python-ipaddress')
print('RHEL/CentOS: yum install python-ipaddress')
exit(2)
Result = namedtuple('Result', ['ip', 'hostname', 'outcome', 'output'])