From 36796842640b4db8676574521aaeeefc7afae480 Mon Sep 17 00:00:00 2001 From: Sina Atalay Date: Fri, 17 May 2024 15:28:08 +0300 Subject: [PATCH] cli: add more unwanted_locations to handle_validation_error --- rendercv/cli.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rendercv/cli.py b/rendercv/cli.py index 7f34f29..9ad16bc 100644 --- a/rendercv/cli.py +++ b/rendercv/cli.py @@ -197,7 +197,7 @@ def handle_validation_error(exception: pydantic.ValidationError): # some locations are not really the locations in the input file, but some # information about the model coming from Pydantic. We need to remove them. # (e.g. avoid stuff like .end_date.literal['present']) - unwanted_locations = ["tagged-union", "list", "literal"] + unwanted_locations = ["tagged-union", "list", "literal", "int", "constrained-str"] for error_object in errors: location = error_object["loc"] new_location = [str(location_element) for location_element in location]