From 49c4b20113e8e1598a77d41794301c135b07614f Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Fri, 28 May 2021 17:09:53 +0530 Subject: [PATCH] Report bad choice values when parsing config --- kitty/conf/utils.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kitty/conf/utils.py b/kitty/conf/utils.py index 425587e75..21ddec98c 100644 --- a/kitty/conf/utils.py +++ b/kitty/conf/utils.py @@ -102,7 +102,7 @@ class Choice: def __call__(self, x: str) -> str: x = x.lower() if x not in self.all_choices: - x = self.defval + raise ValueError(f'The value {x} is not a known choice') return x