From 8630f6190c6590232019730448f8f7d5c6c49a25 Mon Sep 17 00:00:00 2001 From: Steven Robertson Date: Mon, 3 Feb 2020 14:51:50 -0800 Subject: [PATCH] fixed propagating discovered interpreter to future tasks; sys.executable still wrong though --- ansible_mitogen/transport_config.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/ansible_mitogen/transport_config.py b/ansible_mitogen/transport_config.py index f555dc6a..25b5d5d1 100644 --- a/ansible_mitogen/transport_config.py +++ b/ansible_mitogen/transport_config.py @@ -105,12 +105,13 @@ def run_interpreter_discovery_if_necessary(s, task_vars, action): # cache discovered interpreter task_vars['ansible_facts'][discovered_interpreter_config] = s action._connection.has_pipelining = False - # propagate discovered interpreter as fact - action._discovered_interpreter_key = discovered_interpreter_config - action._discovered_interpreter = s else: s = task_vars['ansible_facts'][discovered_interpreter_config] + # propagate discovered interpreter as fact + action._discovered_interpreter_key = discovered_interpreter_config + action._discovered_interpreter = s + action._finding_python_interpreter = False return s