mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-05-08 06:12:51 +00:00
Fix undefined variables, basestring usage, and some associated python3 issues
This commit is contained in:
@@ -64,11 +64,11 @@ class LookupModule(LookupBase):
|
||||
if shelvefile:
|
||||
res = self.read_shelve(shelvefile, key)
|
||||
if res is None:
|
||||
raise AnsibleError("Key %s not found in shelve file %s" % (key, file))
|
||||
raise AnsibleError("Key %s not found in shelve file %s" % (key, shelvefile))
|
||||
# Convert the value read to string
|
||||
ret.append(to_text(res))
|
||||
break
|
||||
else:
|
||||
raise AnsibleError("Could not locate shelve file in lookup: %s" % file)
|
||||
raise AnsibleError("Could not locate shelve file in lookup: %s" % paramvals['file'])
|
||||
|
||||
return ret
|
||||
|
||||
Reference in New Issue
Block a user