Improve error output for util function.
This commit is contained in:
parent
0c632d73b7
commit
b7a8297669
1 changed files with 1 additions and 1 deletions
|
@ -13,4 +13,4 @@ def bool_from_string(input: typing.Union[str, bool]) -> bool:
|
||||||
return True
|
return True
|
||||||
if input.lower() in ("no", "false", "f", "off", "0"):
|
if input.lower() in ("no", "false", "f", "off", "0"):
|
||||||
return False
|
return False
|
||||||
raise ValueError()
|
raise ValueError(f"'{input}' is neither a bool nor a recognized string")
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue