Python 3 related fix in highstate_return.py

In Python 3 key sets of dicts no longer support indexing:
`TypeError: 'dict_keys' object does not support indexing`
This commit is contained in:
AVeenstra 2018-08-08 13:20:05 +02:00 committed by GitHub
parent 10fd4661ff
commit 5e82685b89
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -185,8 +185,8 @@ def _generate_html_table(data, out, level=0, extra_style=''):
else:
new_extra_style = extra_style
if len(subdata) == 1:
name = subdata.keys()[0]
value = subdata.values()[0]
name = list(subdata.keys())[0]
value = list(subdata.values())[0]
print('<tr style="{0}">'.format(
_lookup_style('tr', [row_style])
), file=out)