Skip to content

Commit

Permalink
negated all, min should not return any fact
Browse files Browse the repository at this point in the history
Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
  • Loading branch information
trishnaguha committed Sep 3, 2019
1 parent ce1d302 commit bb28052
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 2 deletions.
4 changes: 3 additions & 1 deletion lib/ansible/module_utils/network/common/facts/facts.py
Expand Up @@ -109,9 +109,11 @@ def get_network_legacy_facts(self, fact_legacy_obj_map, legacy_facts_type=None):
legacy_facts_type = self._gather_subset

runable_subsets = self.gen_runable(legacy_facts_type, frozenset(fact_legacy_obj_map.keys()))
runable_subsets.add('default')
if runable_subsets:
facts = dict()
# default subset should always returned be with legacy facts subsets
if 'default' not in runable_subsets:
runable_subsets.add('default')
self.ansible_facts['ansible_net_gather_subset'] = list(runable_subsets)

instances = list()
Expand Down
2 changes: 1 addition & 1 deletion lib/ansible/module_utils/network/iosxr/facts/facts.py
Expand Up @@ -64,7 +64,7 @@ def get_facts(self, legacy_facts_type=None, resource_facts_type=None, data=None)
:return: the facts gathered
"""
if self.VALID_RESOURCE_SUBSETS:
self.get_network_resources_facts( FACT_RESOURCE_SUBSETS, resource_facts_type, data)
self.get_network_resources_facts(FACT_RESOURCE_SUBSETS, resource_facts_type, data)

if self.VALID_LEGACY_GATHER_SUBSETS:
self.get_network_legacy_facts(FACT_LEGACY_SUBSETS, legacy_facts_type)
Expand Down
Expand Up @@ -7,6 +7,7 @@
The arg spec for the junos facts module.
"""


class FactsArgs(object):
""" The arg spec for the junos facts module
"""
Expand Down

0 comments on commit bb28052

Please sign in to comment.