From 25e0f2f00603aec4b520b1d2b53e871af104e985 Mon Sep 17 00:00:00 2001 From: Emmanuel Garette Date: Mon, 17 Feb 2025 09:43:44 +0100 Subject: [PATCH] fix: translation --- locale/fr/LC_MESSAGES/rougail_output_json.po | 56 +++++++++--------- locale/rougail_output_json.pot | 46 ++++---------- src/rougail/output_json/__init__.py | 5 +- .../fr/LC_MESSAGES/rougail_output_json.mo | Bin 1125 -> 795 bytes 4 files changed, 43 insertions(+), 64 deletions(-) diff --git a/locale/fr/LC_MESSAGES/rougail_output_json.po b/locale/fr/LC_MESSAGES/rougail_output_json.po index b53c2f8..1788859 100644 --- a/locale/fr/LC_MESSAGES/rougail_output_json.po +++ b/locale/fr/LC_MESSAGES/rougail_output_json.po @@ -5,8 +5,8 @@ msgid "" msgstr "" "Project-Id-Version: \n" -"POT-Creation-Date: 2024-11-01 11:03+0100\n" -"PO-Revision-Date: 2024-11-01 11:04+0100\n" +"POT-Creation-Date: 2025-02-17 09:42+0100\n" +"PO-Revision-Date: 2025-02-17 09:43+0100\n" "Last-Translator: \n" "Language-Team: \n" "Language: fr\n" @@ -16,42 +16,42 @@ msgstr "" "Generated-By: pygettext.py 1.5\n" "X-Generator: Poedit 3.5\n" -#: src/rougail/output_exporter/__init__.py:73 +#: src/rougail/output_json/__init__.py:46 +msgid "the \"step.output\" is not set to \"{0}\"" +msgstr "\"step.output\" n'est pas mis à \"{0}\"" + +#: src/rougail/output_json/__init__.py:93 +msgid "Error in config: {0}" +msgstr "Erreur dans la configuration : {0}" + +#: src/rougail/output_json/__init__.py:104 msgid "The following variables are mandatory but have no value:" msgstr "Les variables suiveuses sont obligatoire mais n'ont pas de valeur :" -#: src/rougail/output_exporter/__init__.py:84 +#: src/rougail/output_json/__init__.py:115 msgid "The following variables are inaccessible but are empty and mandatory :" msgstr "Les variables suiveuses sont inaccessibles mais sont vides et obligatoires :" -#: src/rougail/output_exporter/output/console.py:53 -msgid "Undocumented variable" -msgstr "Variable non documentée" +#~ msgid "Undocumented variable" +#~ msgstr "Variable non documentée" -#: src/rougail/output_exporter/output/console.py:54 -msgid "Undocumented but modified variable" -msgstr "Variable non documentée mais modifiée" +#~ msgid "Undocumented but modified variable" +#~ msgstr "Variable non documentée mais modifiée" -#: src/rougail/output_exporter/output/console.py:57 -msgid "Unmodifiable variable" -msgstr "Variable non modifiable" +#~ msgid "Unmodifiable variable" +#~ msgstr "Variable non modifiable" -#: src/rougail/output_exporter/output/console.py:61 -msgid "Default value" -msgstr "Valeur par défaut" +#~ msgid "Default value" +#~ msgstr "Valeur par défaut" -#: src/rougail/output_exporter/output/console.py:62 -msgid "Modified value" -msgstr "Valeur modifiée" +#~ msgid "Modified value" +#~ msgstr "Valeur modifiée" -#: src/rougail/output_exporter/output/console.py:63 -msgid "Original default value" -msgstr "Valeur par défaut d'origine" +#~ msgid "Original default value" +#~ msgstr "Valeur par défaut d'origine" -#: src/rougail/output_exporter/output/console.py:67 -msgid "Caption" -msgstr "Légende" +#~ msgid "Caption" +#~ msgstr "Légende" -#: src/rougail/output_exporter/output/console.py:92 -msgid "Variables:" -msgstr "Variables :" +#~ msgid "Variables:" +#~ msgstr "Variables :" diff --git a/locale/rougail_output_json.pot b/locale/rougail_output_json.pot index 6fd3c0a..0f373a3 100644 --- a/locale/rougail_output_json.pot +++ b/locale/rougail_output_json.pot @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" -"POT-Creation-Date: 2024-11-01 11:03+0100\n" +"POT-Creation-Date: 2025-02-17 09:43+0100\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -15,43 +15,19 @@ msgstr "" "Generated-By: pygettext.py 1.5\n" -#: src/rougail/output_exporter/__init__.py:73 +#: src/rougail/output_json/__init__.py:46 +msgid "the \"step.output\" is not set to \"{0}\"" +msgstr "" + +#: src/rougail/output_json/__init__.py:93 +msgid "Error in config: {0}" +msgstr "" + +#: src/rougail/output_json/__init__.py:104 msgid "The following variables are mandatory but have no value:" msgstr "" -#: src/rougail/output_exporter/__init__.py:84 +#: src/rougail/output_json/__init__.py:115 msgid "The following variables are inaccessible but are empty and mandatory :" msgstr "" -#: src/rougail/output_exporter/output/console.py:53 -msgid "Undocumented variable" -msgstr "" - -#: src/rougail/output_exporter/output/console.py:54 -msgid "Undocumented but modified variable" -msgstr "" - -#: src/rougail/output_exporter/output/console.py:57 -msgid "Unmodifiable variable" -msgstr "" - -#: src/rougail/output_exporter/output/console.py:61 -msgid "Default value" -msgstr "" - -#: src/rougail/output_exporter/output/console.py:62 -msgid "Modified value" -msgstr "" - -#: src/rougail/output_exporter/output/console.py:63 -msgid "Original default value" -msgstr "" - -#: src/rougail/output_exporter/output/console.py:67 -msgid "Caption" -msgstr "" - -#: src/rougail/output_exporter/output/console.py:92 -msgid "Variables:" -msgstr "" - diff --git a/src/rougail/output_json/__init__.py b/src/rougail/output_json/__init__.py index cac4804..620e44b 100644 --- a/src/rougail/output_json/__init__.py +++ b/src/rougail/output_json/__init__.py @@ -90,7 +90,10 @@ class RougailOutputJson: try: mandatories = self.config.value.mandatory() except (ConfigError, PropertiesOptionError) as err: - self.errors.append(f"Error in config: {err}") + self.errors.append(_("Error in config: {0}").format(err)) + return + except ValueError as err: + self.errors.append(str(err)) return for option in mandatories: try: diff --git a/src/rougail/output_json/locale/fr/LC_MESSAGES/rougail_output_json.mo b/src/rougail/output_json/locale/fr/LC_MESSAGES/rougail_output_json.mo index fb7e0aee9ace6a4aa766b4be2f3c9c8ad457fd78..b89f30b3693f1d102e0e24bc0cde0fac4d1eeeb4 100644 GIT binary patch delta 304 zcmY+7y-or_6orQcg~o+0%;&i+!7v=&v0T-YPieLz~`2^=+3VPrRJc2dw!DUW} zKe!7^xa|oM!V2!d-*5%qz*rG^fN_@s&UeGMTs&E8EXA6hjUL3WEqV_=vM@LC`Av~@ ztdbj(a+0#7*pW6&PBF0|iA9-Jz3a34T2QauK2XqX-8Hhl_bc&KrIubI?PwSsUZ*zV b*l5~U=={t-ey^{TV@e`NBQ*Ui_YLA7C3`{U literal 1125 zcmaKq-)a*<6vjubRaca@;6LcaAV>t+G-<1b6)$T4NFkx6q(v_$yC<8G&CD`08_j#@ zL-ZZI%dNhG&)^FPev{2MjYtP(f0>hS&-u>m`L(w6jbYuzUdMLWtJpuV{aU%k*e!4s zyazr3?}Ih)A@~YB06Sm{{0cq=e}WId-!m>>XDq;Z9sC26M1_o{WX`mrl= zC$(aG)E7nO_()_0v5rn;Us5tV9vPWRB{H5YsJa8wJ!Z7!g;xbQQ5vmFTz_l5%kB{~yk6mtGbn zl|w{JrMG+Go1Ik+MC{n;PZYcGFbU7dSX@xVgX5#{ghtYz!adwK*~nQ&jlxB-<$yw#H~cu$H9j3(i`am4d+O3o*% z=VRWizYIQvGlBPbtSOO>Zz0awlk=2RLb#EP3d3_@crrQ1fVe7D-rwZ>e;S_D^mJf| zwJ{CVty^vjIikWMX3^ooh*(U7oW(~nfrK2_y-cRKLTPZ0u1_vzZZW}piZ0^b=wB}EK1u)p