I have a requirements.yml file that lists dependencies for an Ansible Role:
---
- src: git@gitrepo:group/dependency1.git
scm: git
name: name1
- src: git@gitrepo:group/dependency1.git
scm: git
name: name2
These roles do not have any dependencies themselves, and as they are on a private SCM system (among other reasons), they do not need any metadata. However, loading in Ansible dependencies requires that this file exists. Therefore, the dependencies have a blank meta/main.yml to enable using ansible-galaxy.
When installing dependencies using:
ansible-galaxy install --role-file requirements.yml --roles-path foo
after the first dependency was installed, it would error out with:
ERROR! Unexpected Exception: 'NoneType' object has no attribute 'get'
Using the very very verbose output, the error gets located:
galaxy.py", line 394
After experimentation, running the command several more times would progress through the dependencies, one at a time. Nested dependencies would, therefore, fail; as either the parent would install then error out, or ansible-galaxy would think the parent is already installed and skip dependencies.
The question is: how do I stop this error from occurring and get ansible-galaxy to correctly process my dependencies?