Revision c7d04a6b lib/cmdlib.py
b/lib/cmdlib.py | ||
---|---|---|
2736 | 2736 |
@param rlist: a map with node names as keys and OS objects as values |
2737 | 2737 |
|
2738 | 2738 |
@rtype: dict |
2739 |
@return: a dictionary with osnames as keys and as value another map, with |
|
2740 |
nodes as keys and tuples of (path, status, diagnose) as values, eg:: |
|
2739 |
@return: a dictionary with osnames as keys and as value another |
|
2740 |
map, with nodes as keys and tuples of (path, status, diagnose, |
|
2741 |
variants, parameters) as values, eg:: |
|
2741 | 2742 |
|
2742 |
{"debian-etch": {"node1": [(/usr/lib/..., True, ""), |
|
2743 |
{"debian-etch": {"node1": [(/usr/lib/..., True, "", [], []),
|
|
2743 | 2744 |
(/srv/..., False, "invalid api")], |
2744 |
"node2": [(/srv/..., True, "")]} |
|
2745 |
"node2": [(/srv/..., True, "", [], [])]}
|
|
2745 | 2746 |
} |
2746 | 2747 |
|
2747 | 2748 |
""" |
... | ... | |
2754 | 2755 |
for node_name, nr in rlist.items(): |
2755 | 2756 |
if nr.fail_msg or not nr.payload: |
2756 | 2757 |
continue |
2757 |
for name, path, status, diagnose, variants in nr.payload: |
|
2758 |
for name, path, status, diagnose, variants, params in nr.payload:
|
|
2758 | 2759 |
if name not in all_os: |
2759 | 2760 |
# build a list of nodes for this os containing empty lists |
2760 | 2761 |
# for each node in node_list |
2761 | 2762 |
all_os[name] = {} |
2762 | 2763 |
for nname in good_nodes: |
2763 | 2764 |
all_os[name][nname] = [] |
2764 |
all_os[name][node_name].append((path, status, diagnose, variants)) |
|
2765 |
all_os[name][node_name].append((path, status, diagnose, |
|
2766 |
variants, params)) |
|
2765 | 2767 |
return all_os |
2766 | 2768 |
|
2767 | 2769 |
def Exec(self, feedback_fn): |
Also available in: Unified diff