# ERROR: set\_fact is not a legal parameter in an Ansible task or handler

**URL:** <https://forum.ansible.com/t/error-set-fact-is-not-a-legal-parameter-in-an-ansible-task-or-handler/16825>\
**Category:** Ansible Project\
**Created:** [November 19, 2014, 12:42pm UTC](https://forum.ansible.com/t/error-set-fact-is-not-a-legal-parameter-in-an-ansible-task-or-handler/16825 "2014-11-19T12:42:08Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Nico\_K](https://avatars.discourse-cdn.com/v4/letter/n/46a35a/32.png) [@Nico\_K](https://forum.ansible.com/u/Nico_K)\
**Post date:** [November 19, 2014, 12:42pm UTC](https://forum.ansible.com/t/error-set-fact-is-not-a-legal-parameter-in-an-ansible-task-or-handler/16825/1 "2014-11-19T12:42:08Z")

</div>

Hi,

I just updated my ansible environment to the latest version, however my playbooks now no longer run.  
When trying to run it I get: “ERROR: set\_fact is not a legal parameter in an Ansible task or handler”.

This ‘set\_fact’ is performed within a role.

roles/somerole/tasks/main.yml:

- set\_fact:  
some\_fact: whatever  
when: some\_clause

Is this no longer supported?

Regards,  
Nico

---

<div class="post-metadata">

**Author:** ![Dick\_Davies](https://avatars.discourse-cdn.com/v4/letter/d/b9e5f3/32.png) [@Dick\_Davies](https://forum.ansible.com/u/Dick_Davies)\
**Post date:** [November 19, 2014, 1:13pm UTC](https://forum.ansible.com/t/error-set-fact-is-not-a-legal-parameter-in-an-ansible-task-or-handler/16825/2 "2014-11-19T13:13:21Z")

</div>

Hit this yesterday - are you using a Git checkout? see the readme,  
you'll need to pull submodules as well.
