Merge "Document start day of week" into feature/zuulv3
diff --git a/zuul/ansible/callback/zuul_stream.py b/zuul/ansible/callback/zuul_stream.py
index c4473da..c4dd532 100644
--- a/zuul/ansible/callback/zuul_stream.py
+++ b/zuul/ansible/callback/zuul_stream.py
@@ -161,7 +161,7 @@
# Get the hostvars from just one host - the vars we're looking for will
# be identical on all of them
hostvars = self._play._variable_manager._hostvars
- a_host = hostvars.keys()[0]
+ a_host = next(iter(hostvars.keys()))
self.phase = hostvars[a_host]['zuul_execution_phase']
if self.phase != 'run':
self.phase = '{phase}-{index}'.format(
@@ -447,7 +447,7 @@
def _dump_result_dict(self, result_dict):
result_dict = result_dict.copy()
- for key in result_dict.keys():
+ for key in list(result_dict.keys()):
if key.startswith('_ansible') or key == 'zuul_log_id':
del result_dict[key]
return result_dict