From 64871470e221b16b1467adecaa0c0200c2fb3a21 Mon Sep 17 00:00:00 2001 From: Tim Rupp Date: Thu, 2 Nov 2017 13:10:37 -0700 Subject: [PATCH] Removes bigip_pool from the skip file (#32516) --- lib/ansible/modules/network/f5/bigip_pool.py | 10 +++++++++- test/sanity/import/skip.txt | 1 - 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/lib/ansible/modules/network/f5/bigip_pool.py b/lib/ansible/modules/network/f5/bigip_pool.py index 60f74bd5419..04e8c7dfc1e 100644 --- a/lib/ansible/modules/network/f5/bigip_pool.py +++ b/lib/ansible/modules/network/f5/bigip_pool.py @@ -296,7 +296,12 @@ from ansible.module_utils.f5_utils import HAS_F5SDK from ansible.module_utils.f5_utils import F5ModuleError from ansible.module_utils.six import iteritems from collections import defaultdict -from netaddr import IPAddress, AddrFormatError + +try: + from netaddr import IPAddress, AddrFormatError + HAS_NETADDR = True +except ImportError: + HAS_NETADDR = False try: from ansible.module_utils.f5_utils import iControlUnexpectedHTTPError @@ -904,6 +909,9 @@ def main(): if not HAS_F5SDK: raise F5ModuleError("The python f5-sdk module is required") + if not HAS_NETADDR: + raise F5ModuleError("The python netaddr module is required") + spec = ArgumentSpec() client = AnsibleF5Client( diff --git a/test/sanity/import/skip.txt b/test/sanity/import/skip.txt index 3fd09581b23..9610985e034 100644 --- a/test/sanity/import/skip.txt +++ b/test/sanity/import/skip.txt @@ -14,7 +14,6 @@ lib/ansible/modules/cloud/webfaction/webfaction_mailbox.py lib/ansible/modules/cloud/webfaction/webfaction_site.py lib/ansible/modules/clustering/consul_acl.py lib/ansible/modules/network/cloudengine/ce_file_copy.py -lib/ansible/modules/network/f5/bigip_pool.py lib/ansible/modules/network/f5/bigip_provision.py lib/ansible/modules/network/f5/bigip_qkview.py lib/ansible/modules/network/f5/bigip_snmp.py