mirror of
https://github.com/ansible-collections/community.general.git
synced 2024-09-14 20:13:21 +02:00
Fixed - TypeError: unexpected keyword argument (#3649)
* Fixed - TypeError: unexpected keyword argument - File proxmox_group_info.py creates the error "TypeError: get_group() got an unexpected keyword argument \'group\'\r\n'" if a group parameter is used. Issue is an argument naming conflict. After changing the argument name to 'groupid', as used in method ProxmoxGroupInfoAnsible::get_group, testing a Proxmox group name is working now. * Changelog fragment added for #3649 changelog fragment for TypeError: unexpected keyword argument #3649 * Update changelogs/fragments/3649-proxmox_group_info_TypeError.yml Co-authored-by: Felix Fontein <felix@fontein.de> Co-authored-by: Felix Fontein <felix@fontein.de>
This commit is contained in:
parent
aaa0f39f72
commit
0df41241dd
2 changed files with 4 additions and 1 deletions
|
@ -0,0 +1,3 @@
|
||||||
|
---
|
||||||
|
bugfixes:
|
||||||
|
- proxmox_group_info - fix module crash if a ``group`` parameter is used (https://github.com/ansible-collections/community.general/pull/3649).
|
|
@ -131,7 +131,7 @@ def main():
|
||||||
group = module.params['group']
|
group = module.params['group']
|
||||||
|
|
||||||
if group:
|
if group:
|
||||||
groups = [proxmox.get_group(group=group)]
|
groups = [proxmox.get_group(groupid=group)]
|
||||||
else:
|
else:
|
||||||
groups = proxmox.get_groups()
|
groups = proxmox.get_groups()
|
||||||
result['proxmox_groups'] = [group.group for group in groups]
|
result['proxmox_groups'] = [group.group for group in groups]
|
||||||
|
|
Loading…
Reference in a new issue