# netaddr filter and AWX

**URL:** <https://forum.ansible.com/t/netaddr-filter-and-awx/36967>\
**Category:** AWX Project\
**Tags:** awx, ee\
**Created:** [August 9, 2022, 9:09am UTC](https://forum.ansible.com/t/netaddr-filter-and-awx/36967 "2022-08-09T09:09:49Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Edvinas](https://sea1.discourse-cdn.com/ansible/user_avatar/forum.ansible.com/edvinas/32/5406_2.png) [@Edvinas](https://forum.ansible.com/u/Edvinas)\
**Post date:** [August 9, 2022, 9:09am UTC](https://forum.ansible.com/t/netaddr-filter-and-awx/36967/1 "2022-08-09T09:09:49Z")

</div>

Hello, i know i may duplicate, but i need some clarification on using **netaddr** filter with AWX 20.0.1

So, the problem is that i use the playbook which uses **ipv4|ipv6** filters. Getting this error:

_““The conditional check ‘ipv4list.stdout\_lines != (ipv4list.stdout\_lines|ipv4)’ failed. The error was: The ipv4 filter requires python’s netaddr be installed on the ansible controller””_

Tried to install it via **pip install:**

- name: Install python package  
ansible.builtin.pip:  
name: netaddr  
delegate\_to: 127.0.0.1

but it doesn’t help - same message appears.

As i googled i need to create the new execution environment, but I dont understand why - why it’s not enough to install the **netaddr** with pip in currently spawned container ?

Or maybe is there any easier way to workaround this issue ? Thank you

---

<div class="post-metadata">

**Author:** ![AWX\_Project](https://avatars.discourse-cdn.com/v4/letter/a/eada6e/32.png) [@AWX\_Project](https://forum.ansible.com/u/AWX_Project)\
**Post date:** [August 9, 2022, 6:18pm UTC](https://forum.ansible.com/t/netaddr-filter-and-awx/36967/2 "2022-08-09T18:18:32Z")

</div>

AWX runs ansible-runner which create a container from the Execution Environments for the automation to run inside=.  
So installing netaddr with pip inside a current container won’t help because an EE container will be spun up and the automation run there.  
In theory, if you had a long “sleep” in your playbook and installed netaddr inside the running EE container before the task that would work but you would have to do that for every execution.

There is a nice little blog post about creating EEs with Ansible Builder [here](https://www.ansible.com/blog/introduction-to-ansible-builder) as a reference.

-The AWX Team

---

<div class="post-metadata">

**Author:** ![andybourges](https://avatars.discourse-cdn.com/v4/letter/a/a3d4f5/32.png) [@andybourges](https://forum.ansible.com/u/andybourges)\
**Post date:** [August 10, 2022, 4:54am UTC](https://forum.ansible.com/t/netaddr-filter-and-awx/36967/3 "2022-08-10T04:54:58Z")

</div>

Yeah - had the same problem and needed to install netaddr within the EE. For a starter I started the EE via docker and installed netaddr within the image, comitted it and uploaded it to a registry. But on the long run, it’s probably better to have full control over the EE build…
