diff --git a/ansible_mitogen/connection.py b/ansible_mitogen/connection.py index a3f66eacc..d5628889b 100644 --- a/ansible_mitogen/connection.py +++ b/ansible_mitogen/connection.py @@ -41,6 +41,7 @@ import ansible.constants as C import ansible.errors import ansible.plugins.connection +from ansible.plugins.action.normal import ActionModule import mitogen.core @@ -585,7 +586,7 @@ def _get_task_vars(self): if f.f_code.co_name == 'run': f_locals = f.f_locals f_self = f_locals.get('self') - if isinstance(f_self, ansible_mitogen.mixins.ActionModuleMixin): + if isinstance(f_self, ansible_mitogen.mixins.ActionModuleMixin) or (self._play_context.connection == 'httpapi' and isinstance(f_self, ActionModule)): # backref for python interpreter discovery, should be safe because _get_task_vars # is always called before running interpreter discovery self._action = f_self diff --git a/ansible_mitogen/plugins/connection/mitogen_ssh.py b/ansible_mitogen/plugins/connection/mitogen_ssh.py index 75f2d42fb..d977b6fd8 100644 --- a/ansible_mitogen/plugins/connection/mitogen_ssh.py +++ b/ansible_mitogen/plugins/connection/mitogen_ssh.py @@ -75,7 +75,7 @@ class Connection(ansible_mitogen.connection.Connection): transport = 'ssh' - vanilla_class = ansible_mitogen.loaders.connection_loader__get( + (vanilla_class, _) = ansible_mitogen.loaders.connection_loader__get( 'ssh', class_only=True, ) diff --git a/docs/changelog.rst b/docs/changelog.rst index 1fbad229e..6f61614a4 100644 --- a/docs/changelog.rst +++ b/docs/changelog.rst @@ -140,7 +140,7 @@ v0.3.1 (unreleased) * :gh:issue:`878` Kubectl connector fixed with Ansible 2.10 and above -v0.3.0 (2021-11-24) +v0.3.0 (2021-10-28) ------------------- This release separates itself from the v0.2.X releases. Ansible's API changed too much to support backwards compatibility so from now on, v0.2.X releases will be for Ansible < 2.10 and v0.3.X will be for Ansible 2.10+. @@ -153,7 +153,7 @@ This release separates itself from the v0.2.X releases. Ansible's API changed to * :gh:issue:`847` Removed historic Continuous Integration reverse shell -v0.2.10 (2021-11-24) +v0.2.10 (2021-10-28) -------------------- * :gh:issue:`597` mitogen does not support Ansible 2.8 Python interpreter detection @@ -168,6 +168,7 @@ v0.2.10 (2021-11-24) :py:meth:`ansible.plugins.callback.CallbackBase.v2_runner_on_start` * :gh:issue:`775` Test with Python 3.9 * :gh:issue:`775` Add msvcrt to the default module deny list +* :gh:issue:`847` Removed historic Continuous Integration reverse shell v0.2.9 (2019-11-02) diff --git a/docs/images/ansible/run_hostname_100_times_mito.svg b/docs/images/ansible/run_hostname_100_times_mito.svg new file mode 100644 index 000000000..53837ec98 --- /dev/null +++ b/docs/images/ansible/run_hostname_100_times_mito.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/docs/images/ansible/run_hostname_100_times_plain.svg b/docs/images/ansible/run_hostname_100_times_plain.svg new file mode 100644 index 000000000..68cf8af38 --- /dev/null +++ b/docs/images/ansible/run_hostname_100_times_plain.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/docs/svg-boxify.py b/docs/svg-boxify.py new file mode 100644 index 000000000..728b92419 --- /dev/null +++ b/docs/svg-boxify.py @@ -0,0 +1,13 @@ + +# Add viewBox attr to SVGs lacking it, so IE scales properly. + +import lxml.etree +import glob + + +for name in glob.glob('images/*.svg') + glob.glob('images/ansible/*.svg'): + doc = lxml.etree.parse(open(name)) + svg = doc.getroot() + if 'viewBox' not in svg.attrib: + svg.attrib['viewBox'] = '0 0 %(width)s %(height)s' % svg.attrib + open(name, 'w').write(lxml.etree.tostring(svg, xml_declaration=True, encoding='UTF-8'))