Module Expr Str ImportFrom alias Import alias Import alias Import alias Import alias Import alias Import alias Import alias Assign NameStore Call AttributeLoad NameLoad attr NameLoad Assign NameStore Dict Assign NameStore ListLoad Str Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr Str ClassDef bases NameLoad body Pass decorator_list FunctionDef arguments args NameParam NameParam defaults body Expr Str Return BinOpSub CompareGt NameLoad NameLoad CompareLt NameLoad NameLoad decorator_list FunctionDef arguments args defaults body Expr Str Assign NameStore NameLoad Assign NameStore ListLoad Assign NameStore BinOpAdd ListLoad Str Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Str AttributeLoad NameLoad attr For NameStore NameLoad body If Call AttributeLoad AttributeLoad NameLoad attr attr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Str body Assign NameStore Call AttributeLoad NameLoad attr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Str For NameStore NameLoad body Expr Call AttributeLoad NameLoad attr Call AttributeLoad AttributeLoad NameLoad attr attr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Str NameLoad Expr Call AttributeLoad NameLoad attr For NameStore NameLoad body If Call AttributeLoad NameLoad attr Str body Assign NameStore Call NameLoad NameLoad TryExcept body Assign NameStore Call AttributeLoad NameLoad attr BinOpMod Str Call AttributeLoad AttributeLoad NameLoad attr attr SubscriptLoad NameLoad Slice Num NameLoad NameLoad TupleLoad Str Str AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr If Call NameLoad NameLoad NameLoad body Assign NameStore ListLoad NameLoad For NameStore NameLoad body If CompareNotIn NameLoad Call AttributeLoad NameLoad attr body Assign SubscriptStore NameLoad Index Call AttributeLoad NameLoad attr NameLoad handlers ExceptHandler body Expr Call AttributeLoad NameLoad attr BinOpMod Str NameLoad If NameLoad body Expr Call AttributeLoad NameLoad attr Return NameLoad decorator_list FunctionDef arguments args defaults body Expr Str Return Call NameLoad decorator_list FunctionDef arguments args defaults body Assign NameStore ListLoad For NameStore Call NameLoad body If NameLoad body Expr Call AttributeLoad NameLoad attr NameLoad Return NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str TryExcept body With Call NameLoad NameLoad NameStore body Assign NameStore Call AttributeLoad NameLoad attr NameLoad handlers ExceptHandler type NameLoad body Return NameLoad If CompareIn NameLoad Call AttributeLoad NameLoad attr body Return SubscriptLoad NameLoad Index NameLoad Return NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults NameLoad body Expr Str If Call NameLoad NameLoad NameLoad body Assign NameStore ListComp Call AttributeLoad NameLoad attr comprehension NameStore Call AttributeLoad NameLoad attr Str Assign NameStore ListLoad Assign NameStore NameLoad Assign NameStore NameLoad For NameStore NameLoad body If BoolOpAnd NameLoad NameLoad body Assign NameStore Call NameLoad NameLoad Expr Call AttributeLoad NameLoad attr Call NameLoad Call AttributeLoad Call NameLoad NameLoad attr Call NameLoad NameLoad Assign NameStore NameLoad Assign NameStore NameLoad orelse If BoolOpAnd CompareIn NameLoad NameLoad Call NameLoad NameLoad body Assign NameStore Call AttributeLoad NameLoad attr Assign NameStore NameLoad orelse Assign NameStore Call NameLoad NameLoad keyword NameLoad Expr Call AttributeLoad NameLoad attr NameLoad Assign NameStore ListLoad For NameStore NameLoad body AugAssignAdd NameStore NameLoad Return NameLoad decorator_list FunctionDef arguments args NameParam defaults body Assign NameStore Call NameLoad Assign NameStore Num For NameStore Call AttributeLoad NameLoad attr body If CompareEq SubscriptLoad NameLoad Index NameLoad NameLoad body AugAssignAdd NameStore Num If CompareGt NameLoad Num body Return NameLoad orelse Return NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults NameLoad body Expr Str If Call NameLoad NameLoad NameLoad body Assign NameStore ListLoad NameLoad Assign NameStore Call NameLoad Assign NameStore ListLoad Assign NameStore NameLoad For NameStore NameLoad body Assign NameStore Call AttributeLoad NameLoad attr Str If CompareGt Call NameLoad NameLoad Num body Assign NameStore Call AttributeLoad SubscriptLoad NameLoad Index Num attr If CompareIn NameLoad Call AttributeLoad NameLoad attr body Assign NameStore NameLoad If Call NameLoad SubscriptLoad NameLoad Index NameLoad body AugAssignAdd NameStore Call AttributeLoad SubscriptLoad NameLoad Index NameLoad attr Call AttributeLoad Call AttributeLoad Str attr SubscriptLoad NameLoad Slice Num attr Str keyword NameLoad orelse AugAssignAdd NameStore Call AttributeLoad SubscriptLoad NameLoad Index NameLoad attr Call AttributeLoad Call AttributeLoad Str attr SubscriptLoad NameLoad Slice Num attr Str Assign NameStore NameLoad orelse Raise Call NameLoad BinOpMod Str TupleLoad NameLoad Call AttributeLoad Str attr Call AttributeLoad NameLoad attr orelse Assign NameStore NameLoad AugAssignAdd NameStore Call AttributeLoad SubscriptLoad NameLoad Index Str attr SubscriptLoad NameLoad Index Num If NameLoad body Expr Call AttributeLoad NameLoad attr NameLoad If BoolOpAnd NameLoad UnaryOpNot NameLoad body Assign NameStore Call NameLoad NameLoad Return NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Assign NameStore ListComp IfExp Call AttributeLoad NameLoad attr Str TupleLoad Call AttributeLoad NameLoad attr Call AttributeLoad SubscriptLoad NameLoad Slice Num attr Num TupleLoad Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr Num comprehension NameStore NameLoad FunctionDef arguments args NameParam NameParam defaults body For TupleStore NameStore NameStore NameLoad body TryExcept body Assign NameStore Call NameLoad Call NameLoad NameLoad Call NameLoad NameLoad handlers ExceptHandler type NameLoad body Return Num If NameLoad body Return BinOpMult NameLoad NameLoad orelse Return Num decorator_list TryExcept body Return Call NameLoad NameLoad keyword NameLoad handlers ExceptHandler type NameLoad body Import alias Return Call NameLoad NameLoad keyword Call AttributeLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str Assign NameStore Dict Assign NameStore ListLoad For NameStore NameLoad body If CompareIn Str NameLoad body Assign NameStore Call AttributeLoad Str attr SubscriptLoad Call AttributeLoad NameLoad attr Str Slice Num orelse Assign NameStore Str TryExcept body Expr Call AttributeLoad SubscriptLoad NameLoad Index NameLoad attr NameLoad handlers ExceptHandler type NameLoad body Assign SubscriptStore NameLoad Index NameLoad ListLoad NameLoad Assign NameStore Call NameLoad Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr For NameStore NameLoad body Assign NameStore Call NameLoad SubscriptLoad NameLoad Index NameLoad AugAssignAdd NameStore NameLoad Return NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str Expr Call AttributeLoad NameLoad attr Assign NameStore Dict Str Str Str Str Str Num Assign NameStore ListLoad Assign NameStore ListLoad Assign NameStore ListLoad For NameStore NameLoad body TryExcept body Assign NameStore Call AttributeLoad Call AttributeLoad NameLoad attr Str NameLoad attr Assign SubscriptStore NameLoad Index Str Call NameLoad SubscriptLoad NameLoad Index Str Expr Call AttributeLoad NameLoad attr NameLoad handlers ExceptHandler type NameLoad body If CompareNotIn Str NameLoad body AugAssignAdd NameStore Str Assign NameStore Dict Str Call AttributeLoad SubscriptLoad Call NameLoad ListLoad NameLoad Index Num attr Str orelse Assign NameStore Dict Str NameLoad Expr Call AttributeLoad NameLoad attr NameLoad Assign NameStore Call NameLoad NameLoad ListLoad Str Str For NameStore NameLoad body If BoolOpOr CompareIn Str Call AttributeLoad NameLoad attr CompareNotEq SubscriptLoad NameLoad Index Str SubscriptLoad NameLoad Index Str CompareNotEq SubscriptLoad NameLoad Index Str SubscriptLoad NameLoad Index Str CompareNotEq Call NameLoad SubscriptLoad NameLoad Index Str BinOpAdd Call NameLoad SubscriptLoad NameLoad Index Str Num body If Call NameLoad NameLoad body Expr Call AttributeLoad NameLoad attr NameLoad Assign NameStore ListLoad NameLoad orelse Expr Call AttributeLoad NameLoad attr NameLoad Assign NameStore NameLoad Expr Call AttributeLoad NameLoad attr NameLoad Assign NameStore ListLoad For NameStore NameLoad body If Call NameLoad NameLoad body If BoolOpAnd CompareEq Call NameLoad NameLoad Num CompareIn Str Call AttributeLoad SubscriptLoad NameLoad Index Num attr body Expr Call AttributeLoad NameLoad attr SubscriptLoad SubscriptLoad NameLoad Index Num Index Str orelse If CompareEq Call NameLoad NameLoad Num body Expr Call AttributeLoad NameLoad attr BinOpMod Str TupleLoad SubscriptLoad SubscriptLoad NameLoad Index Num Index Str SubscriptLoad SubscriptLoad NameLoad Index Num Index Str SubscriptLoad SubscriptLoad NameLoad Index Num Index Str orelse Expr Call AttributeLoad NameLoad attr BinOpMod Str TupleLoad SubscriptLoad SubscriptLoad NameLoad Index Num Index Str SubscriptLoad SubscriptLoad NameLoad Index Num Index Str SubscriptLoad SubscriptLoad NameLoad Index Num Index Str SubscriptLoad SubscriptLoad NameLoad Index Num Index Str Return NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str Assign NameStore NameLoad Assign NameStore Str Assign NameStore ListLoad For NameStore NameLoad body If CompareIn NameLoad ListLoad Str body Assign NameStore NameLoad If CompareIn NameLoad ListLoad Str body Assign NameStore NameLoad If BoolOpAnd UnaryOpNot NameLoad CompareEq NameLoad Str body Expr Call AttributeLoad NameLoad attr NameLoad Assign NameStore Str orelse If BoolOpAnd UnaryOpNot NameLoad CompareIn NameLoad ListLoad Str CompareEq Call NameLoad NameLoad Num body Pass orelse AugAssignAdd NameStore NameLoad Assign NameStore Call AttributeLoad Call AttributeLoad NameLoad attr attr Str If NameLoad body Expr Call AttributeLoad NameLoad attr NameLoad Return NameLoad decorator_list If CompareEq NameLoad Str body Pass
N/A N/A 
A plugin extendable hostlists infrastructure

This module provides functions for getting a list of hosts
from various systems as well as compressing the list into
a simplified list.

This module uses the hostlists_plugins python scripts
to actually obtain the listings.
 __future__ print_function N/A os N/A sys N/A imp N/A json N/A logging N/A re N/A operator N/A logger N/A N/A logging getLogger __name__ N/A global_plugins N/A N/A SET_OPERATORS N/A - N/A CONF_FILE N/A N/A N/A os path expanduser ~/.hostlists.conf HostListsError N/A Exception N/A N/A N/A cmp_compat N/A N/A a b N/A N/A N/A 
    Simple comparison function
    :param a:
    :param b:
    :return:
     N/A N/A N/A a b N/A a b N/A _get_plugins N/A N/A N/A N/A N/A  Find all the hostlists plugins  N/A plugins global_plugins N/A pluginlist N/A N/A plugin_path N/A N/A /home/y/lib/hostlists N/A N/A N/A os path dirname __file__ ~/.hostlists N/A sys path N/A directory plugin_path N/A N/A N/A N/A N/A os path isdir N/A N/A N/A os path join directory plugins N/A N/A templist N/A N/A os listdir N/A N/A N/A os path join directory plugins N/A item templist N/A N/A N/A N/A pluginlist append N/A N/A N/A os path join N/A N/A N/A os path join directory plugins item N/A N/A N/A pluginlist sort N/A item pluginlist N/A N/A N/A N/A item endswith .py N/A N/A module_file N/A open item N/A N/A N/A mod N/A N/A imp load_module N/A hostlists_plugins_%s N/A N/A N/A os path basename N/A item N/A -3 module_file item N/A .py r N/A imp PY_SOURCE N/A names N/A N/A mod name N/A N/A isinstance names str N/A N/A names N/A names N/A name names N/A N/A N/A name N/A N/A plugins keys N/A N/A N/A plugins N/A N/A N/A name lower mod N/A N/A N/A N/A N/A N/A logger debug N/A Plugin import failed %s: item N/A module_file N/A N/A N/A N/A module_file close N/A plugins N/A get_plugins N/A N/A N/A N/A N/A  Wrap the get_plugins() function so it can be used by plugins
     N/A N/A _get_plugins N/A installed_plugins N/A N/A N/A N/A N/A plugins N/A N/A plugin N/A _get_plugins N/A N/A plugin N/A N/A N/A N/A plugins append plugin N/A plugins N/A get_setting N/A N/A key N/A N/A N/A 
    Get setting values from CONF_FILE
    :param key:
    :return:
     N/A N/A N/A N/A open CONF_FILE cf N/A N/A settings N/A N/A json load cf N/A N/A N/A IOError N/A N/A None N/A N/A key N/A N/A settings keys N/A N/A N/A settings N/A key N/A None N/A expand N/A N/A range_list onepass N/A False N/A N/A 
    Expand a list of lists and set operators into a final host lists
    >>> hostlists.expand(['foo[01-10]','-','foo[04-06]'])
    ['foo09', 'foo08', 'foo07', 'foo02', 'foo01', 'foo03', 'foo10']
    >>>
     N/A N/A isinstance range_list str N/A N/A range_list N/A N/A N/A h strip N/A h N/A N/A range_list split , N/A new_list N/A N/A set1 None N/A operation None N/A item range_list N/A N/A N/A set1 operation N/A N/A set2 N/A expand_item item N/A N/A N/A new_list append N/A list N/A N/A N/A set set1 difference N/A set set2 N/A set1 None N/A operation None N/A N/A N/A N/A item SET_OPERATORS N/A len new_list N/A N/A set1 N/A N/A new_list pop N/A operation item N/A N/A expanded_item N/A expand_item item onepass onepass N/A N/A N/A new_list append expanded_item N/A new_list2 N/A N/A item new_list N/A N/A new_list2 item N/A new_list2 N/A multiple_names N/A N/A plugin N/A N/A N/A plugins N/A _get_plugins N/A count 0 N/A item N/A N/A plugins keys N/A N/A N/A N/A plugins N/A item plugin N/A N/A count 1 N/A N/A count 1 N/A N/A True N/A N/A False N/A expand_item N/A N/A range_list onepass N/A False N/A N/A  Expand a list of plugin:parameters into a list of hosts  N/A N/A isinstance range_list str N/A N/A range_list N/A range_list N/A plugins N/A _get_plugins N/A newlist N/A N/A found_plugin False N/A item range_list N/A N/A temp N/A N/A item split : N/A N/A N/A len temp 1 N/A N/A plugin N/A N/A N/A temp N/A 0 lower N/A N/A plugin N/A N/A plugins keys N/A N/A item None N/A N/A multiple_names N/A plugins N/A plugin N/A N/A newlist N/A N/A N/A plugins N/A plugin expand N/A N/A N/A N/A : join N/A temp N/A 1 strip : name plugin N/A N/A newlist N/A N/A N/A plugins N/A plugin expand N/A N/A N/A N/A : join N/A temp N/A 1 strip : N/A found_plugin True N/A N/A N/A HostListsError N/A plugin %s not found, value plugins are: %s N/A plugin N/A N/A , join N/A N/A plugins keys N/A N/A item None N/A newlist N/A N/A N/A plugins N/A range expand N/A temp N/A 0 N/A item N/A N/A N/A N/A newlist append item N/A N/A found_plugin N/A onepass N/A N/A newlist N/A expand_item newlist N/A newlist N/A multikeysort N/A N/A items columns N/A N/A N/A comparers N/A N/A N/A N/A col startswith - N/A N/A N/A operator itemgetter N/A N/A N/A col N/A 1 strip -1 N/A N/A N/A operator itemgetter N/A N/A col strip 1 N/A col columns comparer N/A N/A left right N/A N/A N/A N/A fn mult comparers N/A N/A N/A N/A result N/A cmp_compat N/A fn left N/A fn right N/A N/A N/A KeyError N/A N/A 0 N/A result N/A N/A N/A mult result N/A N/A 0 N/A N/A N/A N/A N/A sorted items cmp comparer N/A N/A N/A TypeError N/A N/A functools N/A N/A sorted items key N/A N/A functools cmp_to_key comparer N/A compress N/A N/A hostnames N/A N/A N/A 
    Compress a list of host into a more compact range representation
     N/A domain_dict N/A N/A result N/A N/A host hostnames N/A N/A N/A . host N/A N/A domain N/A N/A . join N/A N/A N/A host split . N/A 1 N/A N/A domain N/A N/A N/A N/A N/A N/A domain_dict N/A domain append host N/A N/A N/A KeyError N/A N/A N/A domain_dict N/A domain N/A host N/A domains N/A list N/A N/A domain_dict keys N/A N/A N/A domains sort N/A domain domains N/A N/A hosts N/A compress_domain N/A domain_dict N/A domain N/A result hosts N/A result N/A compress_domain N/A N/A hostnames N/A N/A N/A 
    Compress a list of hosts in a domain into a more compact representation
     N/A N/A N/A hostnames sort N/A prev_dict N/A prefix suffix number 0 N/A items N/A N/A items_block N/A N/A new_hosts N/A N/A host hostnames N/A N/A N/A N/A parsed_dict N/A N/A N/A N/A re match (?P<prefix>[^0-9]+)(?P<number>\d+)(?P<suffix>.*).? host groupdict N/A N/A parsed_dict N/A number_int N/A int N/A parsed_dict N/A number N/A N/A N/A new_hosts append parsed_dict N/A N/A N/A AttributeError N/A N/A N/A . host N/A N/A host . N/A parsed_dict N/A host N/A N/A N/A N/A compress N/A host N/A 0 strip . N/A N/A parsed_dict N/A host host N/A N/A N/A new_hosts append parsed_dict N/A new_hosts N/A multikeysort new_hosts N/A prefix number_int N/A parsed_dict new_hosts N/A N/A N/A N/A host N/A N/A parsed_dict keys N/A N/A parsed_dict N/A prefix N/A prev_dict N/A prefix N/A N/A parsed_dict N/A suffix N/A prev_dict N/A suffix N/A N/A int N/A parsed_dict N/A number N/A N/A int N/A prev_dict N/A number 1 N/A N/A N/A len items_block N/A N/A N/A N/A items append items_block N/A items_block N/A parsed_dict N/A N/A N/A N/A items_block append parsed_dict N/A prev_dict parsed_dict N/A N/A N/A items append items_block N/A result N/A N/A item items N/A N/A N/A len item N/A N/A N/A N/A N/A len item 1 N/A host N/A N/A N/A item N/A 0 keys N/A N/A N/A N/A result append N/A N/A item N/A 0 N/A host N/A N/A N/A N/A len item 1 N/A N/A N/A N/A result append N/A %s%s%s N/A N/A N/A item N/A 0 N/A prefix N/A N/A item N/A 0 N/A number N/A N/A item N/A 0 N/A suffix N/A N/A N/A N/A result append N/A %s[%s-%s]%s N/A N/A N/A item N/A 0 N/A prefix N/A N/A item N/A 0 N/A number N/A N/A item N/A -1 N/A number N/A N/A item N/A 0 N/A suffix N/A result N/A range_split N/A N/A hosts N/A N/A N/A 
    Split up a range string, this needs to separate comma separated
    items unless they are within square brackets and split out set operations
    as separate items.
     N/A in_brackets False N/A current N/A result_list N/A N/A c hosts N/A N/A N/A c N/A [ N/A N/A in_brackets True N/A N/A c N/A ] N/A N/A in_brackets False N/A N/A N/A in_brackets N/A c , N/A N/A N/A N/A result_list append current N/A current N/A N/A N/A N/A in_brackets N/A c N/A , N/A N/A len current 0 N/A N/A N/A N/A current c N/A current N/A N/A N/A N/A current strip strip , N/A current N/A N/A N/A N/A result_list append current N/A result_list N/A N/A N/A __name__ __main__ N/A N/A