I tried to update the underlying python. I reinstalled ansible-core
via pip3
and tried to run an ansible playbook:
$ ansible-playbook -i ansible_inventory.ini playbooknme.yaml --checkmode
ERROR! Unexpected Exception, this is probably a bug: module 'ansible.constants' has no attribute 'CONTROLLER_PYTHON_WARNING'
the full traceback was:
Traceback (most recent call last):
File "/usr/local/bin/ansible-playbook", line 76, in <module>
if C.CONTROLLER_PYTHON_WARNING and not _PY38_MIN:
AttributeError: module '' has no attribute 'CONTROLLER_PYTHON_WARNING'
Sadly, its an Amazon Linux 2, which only has python 3.8 in its repositories packages, which I installed.
I already removed the system Ansible version, which aws provided.
But that’s not working. Maybe smb here has an idea, what to do.