Skip to content

Commit

Permalink
Replace getargspec with getfullargspec
Browse files Browse the repository at this point in the history
Signed-off-by: Martin Nečas <necas.marty@gmail.com>
  • Loading branch information
mnecas committed Jan 18, 2023
1 parent 5be4253 commit 9ea1519
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions plugins/module_utils/ovirt.py
Original file line number Diff line number Diff line change
Expand Up @@ -280,7 +280,7 @@ def search_by_attributes(service, list_params=None, **kwargs):
"""
list_params = list_params or {}
# Check if 'list' method support search(look for search parameter):
if 'search' in inspect.getargspec(service.list)[0]:
if 'search' in inspect.getfullargspec(service.list)[0]:
res = service.list(
# There must be double quotes around name, because some oVirt resources it's possible to create then with space in name.
search=' and '.join('{0}="{1}"'.format(k, v) for k, v in kwargs.items()),
Expand Down Expand Up @@ -308,7 +308,7 @@ def search_by_name(service, name, **kwargs):
:return: Entity object returned by Python SDK
"""
# Check if 'list' method support search(look for search parameter):
if 'search' in inspect.getargspec(service.list)[0]:
if 'search' in inspect.getfullargspec(service.list)[0]:
res = service.list(
# There must be double quotes around name, because some oVirt resources it's possible to create then with space in name.
search='name="{name}"'.format(name=name)
Expand Down

0 comments on commit 9ea1519

Please sign in to comment.