From 5c31195e91b106b28337264606ae218920cabf06 Mon Sep 17 00:00:00 2001 From: Adam Turner <9087854+aa-turner@users.noreply.github.com> Date: Mon, 24 Jul 2023 13:33:12 +0100 Subject: [PATCH] Include the translated string in babel error messages --- utils/babel_runner.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/utils/babel_runner.py b/utils/babel_runner.py index 5e62efe86ca..cd228f4b10b 100644 --- a/utils/babel_runner.py +++ b/utils/babel_runner.py @@ -181,7 +181,8 @@ def run_compile(): for message, errors in catalog.check(): for error in errors: total_errors += 1 - log.error('error: %s:%d: %s', po_file, message.lineno, error) + log.error('error: %s:%d: %s\nerror: in message string: %s', + po_file, message.lineno, error, message.string) mo_file = os.path.join(directory, locale, 'LC_MESSAGES', 'sphinx.mo') log.info('compiling catalog %s to %s', po_file, mo_file)