-
Bug
-
Resolution: Done
-
Undefined
-
None
-
Unspecified
-
False
-
-
False
-
-
-
Critical
vmware.vmware.guest_info fails with the following error when using the guest_name parameter to specify the name of an existing VM in vcenter instance:
fatal: [localhost]: FAILED! => { "changed": false, "module_stderr": "Traceback (most recent call last):\n File \"/root/.ansible/tmp/ansible-tmp-1718189429.8212805-84-53263171568675/AnsiballZ_guest_info.py\", line 107, in <module>\n _ansiballz_main()\n File \"/root/.ansible/tmp/ansible-tmp-1718189429.8212805-84-53263171568675/AnsiballZ_guest_info.py\", line 99, in _ansiballz_main\n invoke_module(zipped_mod, temp_path, ANSIBALLZ_PARAMS)\n File \"/root/.ansible/tmp/ansible-tmp-1718189429.8212805-84-53263171568675/AnsiballZ_guest_info.py\", line 47, in invoke_module\n runpy.run_module(mod_name='ansible_collections.vmware.vmware.plugins.modules.guest_info', init_globals=dict(_module_fqn='ansible_collections.vmware.vmware.plugins.modules.guest_info', _modlib_path=modlib_path),\n File \"/usr/lib64/python3.9/runpy.py\", line 225, in run_module\n return _run_module_code(code, init_globals, run_name, mod_spec)\n File \"/usr/lib64/python3.9/runpy.py\", line 97, in _run_module_code\n _run_code(code, mod_globals, init_globals,\n File \"/usr/lib64/python3.9/runpy.py\", line 87, in _run_code\n exec(code, run_globals)\n File \"/tmp/ansible_vmware.vmware.guest_info_payload_ddvft1g4/ansible_vmware.vmware.guest_info_payload.zip/ansible_collections/vmware/vmware/plugins/modules/guest_info.py\", line 170, in <module>\n File \"/tmp/ansible_vmware.vmware.guest_info_payload_ddvft1g4/ansible_vmware.vmware.guest_info_payload.zip/ansible_collections/vmware/vmware/plugins/modules/guest_info.py\", line 165, in main\n File \"/tmp/ansible_vmware.vmware.guest_info_payload_ddvft1g4/ansible_vmware.vmware.guest_info_payload.zip/ansible_collections/vmware/vmware/plugins/modules/guest_info.py\", line 116, in get_guest_info\nTypeError: get_vm_by_name() got an unexpected keyword argument 'name'\n", "module_stdout": "", "msg": "MODULE FAILURE\nSee stdout/stderr for the exact error", "rc": 1 }
It looks like there are two `get_vm_by_name` methods in VmwareRestClient class and are colliding: