mirror of
https://github.com/mofeng-git/One-KVM.git
synced 2026-03-17 08:26:54 +08:00
f-strings
This commit is contained in:
@@ -36,7 +36,7 @@ def load_yaml_file(path: str) -> Any:
|
||||
return yaml.load(yaml_file, _YamlLoader)
|
||||
except Exception:
|
||||
# Reraise internal exception as standard ValueError and show the incorrect file
|
||||
raise ValueError("Incorrect YAML syntax in file %r" % (path))
|
||||
raise ValueError(f"Incorrect YAML syntax in file {path!r}")
|
||||
|
||||
|
||||
class _YamlLoader(yaml.SafeLoader):
|
||||
|
||||
Reference in New Issue
Block a user