The commit
23b6c90 introduced a regression when traversing leaf nodes.
The issue is that it traverses the keys of a `dict` returned by
`nodes_by_id`, not the actual `items` of the node. That resulted in an
500 error because it tried to treat `str` as a `dict` and failed.
Signed-off-by: Boris Ranto <branto@redhat.com>
if node_id >= 0:
osds.add(node_id)
else:
- for desc_node in nodes_by_id[node_id]:
+ for desc_node in nodes_by_id[node_id]['items']:
# Short circuit another iteration to find the emit
# and assume anything we've done a chooseleaf on
# is going to be part of the selected set of osds