summaryrefslogtreecommitdiff
path: root/python
diff options
context:
space:
mode:
Diffstat (limited to 'python')
-rwxr-xr-xpython/vyos/template.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/python/vyos/template.py b/python/vyos/template.py
index 596f9e8c5..2a783bc74 100755
--- a/python/vyos/template.py
+++ b/python/vyos/template.py
@@ -274,9 +274,9 @@ def netmask_from_ipv4(address):
Example:
- 172.18.201.10 -> 255.255.255.128
"""
- from netifaces import interfaces
- from netifaces import ifaddresses
- from netifaces import AF_INET
+ from netifaces import interfaces # pylint: disable = no-name-in-module
+ from netifaces import ifaddresses # pylint: disable = no-name-in-module
+ from socket import AF_INET
for interface in interfaces():
tmp = ifaddresses(interface)
if AF_INET in tmp: