ansible-collections / vmware.vmware_rest

Ansible Collection for VMWare (REST modules)
https://ansible-collections.github.io/vmware.vmware_rest/
GNU General Public License v3.0
131 stars 64 forks source link

content_library_item_info: Unsupported property with name: library_id?library_id #463

Closed ephracis closed 8 months ago

ephracis commented 8 months ago
SUMMARY

When trying to use the module content_library_item_info to get a list of items inside a given library, the module fails with the following error message:

Unsupported property with name: library_id?library_id

This is due to a malformed URL:

https://vcenter.example.com/api/content/library/item?library_id?library_id=23592d7a-0ad4-439b-9aa6-57680ade5d6b

It should really be:

https://vcenter.example.com/api/content/library/item?library_id=23592d7a-0ad4-439b-9aa6-57680ade5d6b
ISSUE TYPE
COMPONENT NAME

content_library_item_info

ANSIBLE VERSION
ansible [core 2.15.8]
  config file = /home/chre07/.ansible.cfg
  configured module search path = ['/home/chre07/.ansible/plugins/modules', '/usr/share/ansible/plugins/modules']
  ansible python module location = /tmp/venv/lib64/python3.9/site-packages/ansible
  ansible collection location = /home/chre07/.ansible/collections:/usr/share/ansible/collections
  executable location = /tmp/venv/bin/ansible
  python version = 3.9.18 (main, Sep 22 2023, 17:58:34) [GCC 8.5.0 20210514 (Red Hat 8.5.0-20)] (/tmp/venv/bin/python3)
  jinja version = 3.1.2
  libyaml = True
COLLECTION VERSION
# /home/chre07/.ansible/collections/ansible_collections
Collection         Version
------------------ -------
vmware.vmware_rest 3.0.0
STEPS TO REPRODUCE
- name: Get the list of items of the NFS library
  vmware.vmware_rest.content_library_item_info:
    library_id: '{{ nfs_lib.id }}'
  register: lib_items
EXPECTED RESULTS

It should run without errors.

ACTUAL RESULTS
Unsupported property with name: library_id?library_id