# implementation error -- msg to explain the error is required

**URL:** <https://forum.ansible.com/t/implementation-error-msg-to-explain-the-error-is-required/13024>\
**Category:** Ansible Project\
**Created:** [June 26, 2013, 10:23pm UTC](https://forum.ansible.com/t/implementation-error-msg-to-explain-the-error-is-required/13024 "2013-06-26T22:23:25Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![James\_Martin](https://avatars.discourse-cdn.com/v4/letter/j/f14d63/32.png) [@James\_Martin](https://forum.ansible.com/u/James_Martin)\
**Post date:** [June 26, 2013, 10:23pm UTC](https://forum.ansible.com/t/implementation-error-msg-to-explain-the-error-is-required/13024/1 "2013-06-26T22:23:25Z")

</div>

I'm getting this golden nugget when trying to launch a stack with the  
cloudformation module:

I found the relevant code in module\_common.py, but I'm not sure what  
it's trying to tell me.

Any ideas?

"TASK: [launch zombie stack] \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*  
failed: [127.0.0.1] =\> {"failed": true, "item": "", "parsed": false}  
invalid output was: Traceback (most recent call last):  
&nbsp;&nbsp;File "/Users/jmartin/.ansible/tmp/ansible-1372284392.12-102223282280847/cloudformation",  
line 1156, in \<module\>  
&nbsp;&nbsp;&nbsp;&nbsp;main()  
&nbsp;&nbsp;File "/Users/jmartin/.ansible/tmp/ansible-1372284392.12-102223282280847/cloudformation",  
line 199, in main  
&nbsp;&nbsp;&nbsp;&nbsp;module.fail\_json(\*\*result)  
&nbsp;&nbsp;File "/Users/jmartin/.ansible/tmp/ansible-1372284392.12-102223282280847/cloudformation",  
line 994, in fail\_json  
&nbsp;&nbsp;&nbsp;&nbsp;assert 'msg' in kwargs, "implementation error -- msg to explain  
the error is required"  
AssertionError: implementation error -- msg to explain the error is required"

Thanks,

James

---

<div class="post-metadata">

**Author:** ![Michael\_DeHaan2](https://avatars.discourse-cdn.com/v4/letter/m/da6949/32.png) [@Michael\_DeHaan2](https://forum.ansible.com/u/Michael_DeHaan2)\
**Post date:** [June 26, 2013, 10:32pm UTC](https://forum.ansible.com/t/implementation-error-msg-to-explain-the-error-is-required/13024/2 "2013-06-26T22:32:31Z")

</div>

when you call fail\_json you need to pass a “msg” argument.

---

<div class="post-metadata">

**Author:** ![Boris2](https://avatars.discourse-cdn.com/v4/letter/b/a88e57/32.png) [@Boris2](https://forum.ansible.com/u/Boris2)\
**Post date:** [June 28, 2013, 12:48am UTC](https://forum.ansible.com/t/implementation-error-msg-to-explain-the-error-is-required/13024/3 "2013-06-28T00:48:36Z")

</div>

I just got the same error while using cloudformation module. It looks like cloudformation module is incorrectly passing ‘output’ instead of ‘msg’ argument.

[https://github.com/ansible/ansible/blob/devel/library/cloud/cloudformation](https://github.com/ansible/ansible/blob/devel/library/cloud/cloudformation) (line 198-199):

```auto

                result = {'changed': False, ' **output**': error_msg}
                module.fail_json(**result)

```

---

<div class="post-metadata">

**Author:** ![James\_Martin2](https://avatars.discourse-cdn.com/v4/letter/j/b9e5f3/32.png) [@James\_Martin2](https://forum.ansible.com/u/James_Martin2)\
**Post date:** [June 28, 2013, 1:08pm UTC](https://forum.ansible.com/t/implementation-error-msg-to-explain-the-error-is-required/13024/4 "2013-06-28T13:08:58Z")

</div>

Boris,

I just put in a pull request for this bug yesterday. Hopefully Michael will merge it soon.

James
