fix: remove collection_list when action plugin is fetch

pull/973/head
gboutry 2 years ago
parent a154b7b134
commit 12cc608465
No known key found for this signature in database
GPG Key ID: DC4A52BE8F2B0AD1

@ -130,11 +130,13 @@ def wrap_action_loader__get(name, *args, **kwargs):
action plugins outside the Ansible tree.
"""
get_kwargs = {'class_only': True}
if name in ('fetch',):
name = 'mitogen_' + name
if ansible.__version__ >= '2.8':
get_kwargs['collection_list'] = kwargs.pop('collection_list', None)
if name in ('fetch',):
name = 'mitogen_' + name
get_kwargs['collection_list'] = None
klass = ansible_mitogen.loaders.action_loader__get(name, **get_kwargs)
if klass:
bases = (ansible_mitogen.mixins.ActionModuleMixin, klass)

@ -17,6 +17,12 @@ Release Notes
To avail of fixes in an unreleased version, please download a ZIP file
`directly from GitHub <https://github.com/dw/mitogen/>`_.
v0.2.11dev0
-----------
* :gh:issue:`971` Fix ansible action plugin lookup when resolving fetch inside a collection
v0.2.10 (2021-10-28)
--------------------

Loading…
Cancel
Save