If no interpreter is configured in ansible.cfg and ansible_interpreter_python is not set, then Ansible >= 2.8 performs interpreter discovery on targets to determine the path of a suitable Python executable (e.g. /usr/bin/python3.8). When Mitogen is involved it should behave the same as vanilla Ansible. Currently it does not always
Ansible + Mitogen 0.3.8 ignores ansible_facts.discovered_python_interpreter in the following cases
In these cases Mitogen often falls back to /usr/bin/python. This has become more apparent while adding Ansible 10 (ansible-core 2.17) support, because Ansible 10 drops Python 2.x support on targets.
If no interpreter is configured in ansible.cfg and
ansible_interpreter_pythonis not set, then Ansible >= 2.8 performs interpreter discovery on targets to determine the path of a suitable Python executable (e.g./usr/bin/python3.8). When Mitogen is involved it should behave the same as vanilla Ansible. Currently it does not alwaysAnsible + Mitogen 0.3.8 ignores
ansible_facts.discovered_python_interpreterin the following casesIn these cases Mitogen often falls back to
/usr/bin/python. This has become more apparent while adding Ansible 10 (ansible-core 2.17) support, because Ansible 10 drops Python 2.x support on targets.