From 57a9353493da2fd8ce124ab08b0c192b27a41467 Mon Sep 17 00:00:00 2001 From: mcflugen Date: Mon, 1 Apr 2024 13:25:33 -0600 Subject: [PATCH] better error message for existing output dir --- babelizer/errors.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/babelizer/errors.py b/babelizer/errors.py index edf1abd..d478790 100644 --- a/babelizer/errors.py +++ b/babelizer/errors.py @@ -35,7 +35,9 @@ class ScanError(BabelizeError): class OutputDirExistsError(BabelizeError): """An exception used when the directory for babelized output exists.""" - pass + def __str__(self) -> str: + """Render a user-readable error message.""" + return f"output directory exists: {self._message}" class SetupPyError(BabelizeError):