From 47c6a461e5078b24d0313b933e45d636bbda8b88 Mon Sep 17 00:00:00 2001 From: Ines Montani Date: Sun, 27 Sep 2020 22:41:00 +0200 Subject: [PATCH] Revert except all in CLI error handling [ci skip] --- spacy/cli/_util.py | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/spacy/cli/_util.py b/spacy/cli/_util.py index f4a31d68b..68cb572ea 100644 --- a/spacy/cli/_util.py +++ b/spacy/cli/_util.py @@ -258,10 +258,8 @@ def show_validation_error( ) print(f"{COMMAND} init fill-config {config_path} --base {config_path}\n") sys.exit(1) - except Exception as e: - msg.fail("Error while loading the config") - print(e) - sys.exit(1) + except InterpolationError as e: + msg.fail("Config validation error", e, exits=1) def import_code(code_path: Optional[Union[Path, str]]) -> None: