From 300d4603ca725dfb8749e466eabe0561ad54cb6b Mon Sep 17 00:00:00 2001 From: Devaev Maxim Date: Thu, 19 Sep 2019 06:47:54 +0300 Subject: fixed config loading --- kvmd/yamlconf/__init__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'kvmd/yamlconf') diff --git a/kvmd/yamlconf/__init__.py b/kvmd/yamlconf/__init__.py index b0bc356f..a253d449 100644 --- a/kvmd/yamlconf/__init__.py +++ b/kvmd/yamlconf/__init__.py @@ -162,7 +162,7 @@ def make_config(raw: Dict[str, Any], scheme: Dict[str, Any], _keys: Tuple[str, . value = raw.get(key, option.default) try: value = option.type(value) - except ValueError as err: + except (TypeError, ValueError) as err: raise ConfigError(f"Invalid value {value!r} for key {make_full_name(key)!r}: {err}") config[key] = value -- cgit v1.2.3