def recursive_list_removal(inventory, purge_list):
    for item in purge_list:
        for _item in inventory:
            if item == _item:
                inventory.pop(inventory.index(item))
Remove items from a list.
dataset/ETHPy150Open openstack/openstack-ansible/scripts/inventory-manage.py/recursive_list_removal