I'm not sure what you are trying to do, but it looks like you are trying to instantiate a connection plugin from a module, this is not normally how things work.
Connection plugins are provided the vars they declare in config when they are loaded from the task executor, trying to load/create it from the module you bypass all this. Also modules do not have any data not explicitly passed to them, as they are designed to run on the 'target' and you don't want to disclose on 'hostA' all the secrets for hostsB to hostsX, so of course they do not have access to the variables you need. If this was possible in 2.9, which it was not, it would have been a major bug and security issue. The 'working' example you show seems to get a full dictionary of the parameters passed to the module via the 'endpoint' option, I don't see any other way that would work. -- ---------- Brian Coca -- You received this message because you are subscribed to the Google Groups "Ansible Development" group. To unsubscribe from this group and stop receiving emails from it, send an email to ansible-devel+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-devel/CACVha7du0my%3DhqMVh%2BOygJJy4NbyUMwa_uJnQ7hnnKFM8e8vTA%40mail.gmail.com.