fix linting

This commit is contained in:
Robert Kaussow 2023-06-15 09:14:51 +02:00
parent 502a67f9b3
commit b009ce4acf
Signed by: xoxys
GPG Key ID: 4E692A2EAECC03C0
2 changed files with 2 additions and 2 deletions

View File

@ -321,7 +321,7 @@ class StandardLoader():
try:
spec.loader.exec_module(module)
except (ImportError, NameError) as e:
sysexit_with_message(f"Failed to load roles file {filename}: \n {str(e)}")
sysexit_with_message(f"Failed to load roles file {filename}: \n {e!s}")
try:
for _name, obj in inspect.getmembers(module):

View File

@ -490,7 +490,7 @@ def extract_from_list(blocks, candidates):
results.extend(add_action_type(block[candidate], candidate, meta_data))
elif block[candidate] is not None:
raise RuntimeError(
f"Key '{candidate}' defined, but bad value: '{str(block[candidate])}'"
f"Key '{candidate}' defined, but bad value: '{block[candidate]!s}'"
)
return results