nutanix / nutanix.ansible

Official Nutanix Ansible collections
GNU General Public License v3.0
67 stars 36 forks source link

[Bug] "Error: Module unable to decode valid JSON on stdin" in module ntnx_prism_vm_inventory.py #224

Closed peshay closed 2 years ago

peshay commented 2 years ago

Describe the bug When using the ansible inventory plugin from the collection 1.2.0 I get following error message: {"msg": "Error: Module unable to decode valid JSON on stdin. Unable to figure out what parameters were passed", "failed": true} With version 1.1.0 it is working just fine.

To Reproduce Steps to reproduce the behavior:

  1. ansible command: ansible-inventory -i inventories/nutanix.yml --graph
  2. sample playbook used
    plugin: nutanix.ncp.ntnx_prism_vm_inventory
    nutanix_hostname: 1.2.3.4
    nutanix_port: 9440
    nutanix_username: admin
    nutanix_password: ********
    validate_certs: false
    cache: true
    cache_plugin: jsonfile
    cache_timeout: 3600
    cache_connection: /tmp
    cache_prefix: nx_

Ansible Version

ansible-inventory [core 2.12.6]
  python version = 3.9.7 (v3.9.7:1016ef3790, Aug 30 2021, 16:39:15) [Clang 6.0 (clang-600.0.57)]
  jinja version = 3.1.2
  libyaml = True