From eaef33321554d5fea067243797b3a451364271a7 Mon Sep 17 00:00:00 2001 From: mzizzi Date: Thu, 15 Sep 2016 12:55:28 -0400 Subject: [PATCH] cloudformation stack events itertools.imap bugfix (#4868) --- lib/ansible/modules/cloud/amazon/cloudformation.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/lib/ansible/modules/cloud/amazon/cloudformation.py b/lib/ansible/modules/cloud/amazon/cloudformation.py index d85ae37ae58..1c61483c1a8 100644 --- a/lib/ansible/modules/cloud/amazon/cloudformation.py +++ b/lib/ansible/modules/cloud/amazon/cloudformation.py @@ -203,28 +203,28 @@ def stack_operation(cfn, stack_name, operation): if 'yes' in existed: result = dict(changed=True, output='Stack Deleted', - events=map(str, list(stack.describe_events()))) + events=list(map(str, list(stack.describe_events())))) else: result = dict(changed= True, output='Stack Not Found') break if '%s_COMPLETE' % operation == stack.stack_status: result = dict(changed=True, - events = map(str, list(stack.describe_events())), + events = list(map(str, list(stack.describe_events()))), output = 'Stack %s complete' % operation) break if 'ROLLBACK_COMPLETE' == stack.stack_status or '%s_ROLLBACK_COMPLETE' % operation == stack.stack_status: result = dict(changed=True, failed=True, - events = map(str, list(stack.describe_events())), + events = list(map(str, list(stack.describe_events()))), output = 'Problem with %s. Rollback complete' % operation) break elif '%s_FAILED' % operation == stack.stack_status: result = dict(changed=True, failed=True, - events = map(str, list(stack.describe_events())), + events = list(map(str, list(stack.describe_events()))), output = 'Stack %s failed' % operation) break elif '%s_ROLLBACK_FAILED' % operation == stack.stack_status: result = dict(changed=True, failed=True, - events = map(str, list(stack.describe_events())), + events = list(map(str, list(stack.describe_events()))), output = 'Stack %s rollback failed' % operation) break else: