# ansible-galaxy no longer working

**URL:** <https://forum.ansible.com/t/ansible-galaxy-no-longer-working/38818>\
**Category:** Ansible Project\
**Tags:** rhel, galaxy-ng\
**Created:** [June 24, 2024, 6:03pm UTC](https://forum.ansible.com/t/ansible-galaxy-no-longer-working/38818 "2024-06-24T18:03:21Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Andrew\_Meyer1](https://avatars.discourse-cdn.com/v4/letter/a/df705f/32.png) [@Andrew\_Meyer1](https://forum.ansible.com/u/Andrew_Meyer1)\
**Post date:** [June 24, 2024, 6:03pm UTC](https://forum.ansible.com/t/ansible-galaxy-no-longer-working/38818/1 "2024-06-24T18:03:21Z")

</div>

Hello,  
About a week ago I updated ansible and am getting the following error:

[ansible@jump04 ansible1]$ /usr/bin/ansible-galaxy install --force -p roles -r /opt/syseng/automation/ansible1/roles.yml --ignore-errors  
Starting galaxy role install process  
ERROR! Unexpected Exception, this is probably a bug: ‘version’  
to see the full traceback, use -vvv  
[ansible@jump04 ansible1]$

ansible [core 2.14.14]  
config file = /opt/syseng/automation/ansible1/ansible.cfg  
configured module search path = [‘/opt/syseng/automation/ansible1/{{ ANSIBLE\_HOME ~ "/plugins/modules’, ‘/usr/share/ansible/plugins/modules’, ‘/opt/syseng/automation/ansible1/library" }}’]  
ansible python module location = /usr/lib/python3.9/site-packages/ansible  
ansible collection location = /opt/syseng/automation/ansible1/ansible\_collections:/opt/syseng/automation/ansible1/collection  
executable location = /usr/bin/ansible  
python version = 3.9.18 (main, Jan 24 2024, 00:00:00) [GCC 11.4.1 20231218 (Red Hat 11.4.1-3)] (/usr/bin/python3)  
jinja version = 3.1.2  
libyaml = True  
[ansible@jump04 ansible1]$

I’m running:  
RHEL 9.4

---

<div class="post-metadata">

**Author:** ![utoddl](https://sea1.discourse-cdn.com/ansible/user_avatar/forum.ansible.com/utoddl/32/249_2.png) [@utoddl](https://forum.ansible.com/u/utoddl)\
**Post date:** [June 24, 2024, 6:52pm UTC](https://forum.ansible.com/t/ansible-galaxy-no-longer-working/38818/2 "2024-06-24T18:52:13Z")

</div>

Can you show us what your requirements file contains? (And I’m curious why you call it “/opt/syseng/automation/ansible1/roles.yml” rather than “/something/something/requirements.yml”.)

Was there anything interesting when you ran it with “-vvv”?

---

<div class="post-metadata">

**Author:** ![Andrew\_Meyer1](https://avatars.discourse-cdn.com/v4/letter/a/df705f/32.png) [@Andrew\_Meyer1](https://forum.ansible.com/u/Andrew_Meyer1)\
**Post date:** [June 24, 2024, 7:11pm UTC](https://forum.ansible.com/t/ansible-galaxy-no-longer-working/38818/3 "2024-06-24T19:11:45Z")

</div>

ansible-galaxy just pulls down my roles. I just haven’t changed it yet.

---

<div class="post-metadata">

**Author:** ![Andrew\_Meyer1](https://avatars.discourse-cdn.com/v4/letter/a/df705f/32.png) [@Andrew\_Meyer1](https://forum.ansible.com/u/Andrew_Meyer1)\
**Post date:** [June 25, 2024, 9:37pm UTC](https://forum.ansible.com/t/ansible-galaxy-no-longer-working/38818/4 "2024-06-25T21:37:03Z")

</div>

Also I don’t have a requirements.yml. I use the roles.yml.

---

<div class="post-metadata">

**Author:** ![Andrew\_Meyer1](https://avatars.discourse-cdn.com/v4/letter/a/df705f/32.png) [@Andrew\_Meyer1](https://forum.ansible.com/u/Andrew_Meyer1)\
**Post date:** [July 10, 2024, 4:04am UTC](https://forum.ansible.com/t/ansible-galaxy-no-longer-working/38818/5 "2024-07-10T04:04:14Z")

</div>

Hi I am getting this same error on RHEL 8 and RHEL 9 using the latest version of ansible on BOTH.

Also does the yaml file I call need to be requirements.yml? I prefer it be called roles.yml since I’m using this to install all of my roles. It just makes sense to me for now. I have no problem changing it…

Here is the output:

[ansible@jump05 ansible1]$ /usr/bin/ansible-galaxy role install -p roles -r /opt/syseng/automation/ansible1/roles.yml -f -i -vvv  
ansible-galaxy [core 2.16.3]  
config file = /opt/syseng/automation/ansible1/ansible.cfg  
configured module search path = [‘/opt/syseng/automation/ansible1/{{ ANSIBLE\_HOME ~ "/plugins/modules’, ‘/usr/share/ansible/plugins/modules’, ‘/opt/syseng/automation/ansible1/library" }}’]  
ansible python module location = /usr/lib/python3.12/site-packages/ansible  
ansible collection location = /opt/syseng/automation/ansible1/ansible\_collections:/opt/syseng/automation/ansible1/collection  
executable location = /usr/bin/ansible-galaxy  
python version = 3.12.3 (main, Jun 19 2024, 10:06:03) [GCC 8.5.0 20210514 (Red Hat 8.5.0-22)] (/usr/bin/python3.12)  
jinja version = 3.1.2  
libyaml = True  
Using /opt/syseng/automation/ansible1/ansible.cfg as config file  
Reading requirement file at ‘/opt/syseng/automation/ansible1/roles.yml’

There is a gap here because it lists all of the my repos and I would rather not post that infromation.

Starting galaxy role install process  
Processing role grafana\_new  
ERROR! Unexpected Exception, this is probably a bug: ‘version’  
the full traceback was:

Traceback (most recent call last):  
File “/usr/lib/python3.12/site-packages/ansible/cli/ **init**.py”, line 659, in cli\_executor  
exit\_code = cli.run()  
^^^^^^^^^  
File “/usr/lib/python3.12/site-packages/ansible/cli/galaxy.py”, line 749, in run  
return context.CLIARGS’func’  
^^^^^^^^^^^^^^^^^^^^^^^^^  
File “/usr/lib/python3.12/site-packages/ansible/cli/galaxy.py”, line 120, in method\_wrapper  
return wrapped\_method(\*args, \*\*kwargs)  
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^  
File “/usr/lib/python3.12/site-packages/ansible/cli/galaxy.py”, line 1403, in execute\_install  
self.\_execute\_install\_role(role\_requirements)  
File “/usr/lib/python3.12/site-packages/ansible/cli/galaxy.py”, line 1487, in \_execute\_install\_role  
if role.install\_info[‘version’] != role.version or force:

```auto
KeyError: 'version'
[ansible@jump05 ansible1]$
```
