From d9256a6d5aef80f2892aa64821f2cafd0645cc4c Mon Sep 17 00:00:00 2001 From: ChanceNCounter Date: Tue, 9 Nov 2021 16:49:31 -0800 Subject: [PATCH] fix potential circular import down the stretch --- lingua_franca/format.py | 5 ++--- lingua_franca/parse.py | 5 ++--- setup.py | 2 +- 3 files changed, 5 insertions(+), 7 deletions(-) diff --git a/lingua_franca/format.py b/lingua_franca/format.py index 7be87167..468a4ac6 100755 --- a/lingua_franca/format.py +++ b/lingua_franca/format.py @@ -37,9 +37,6 @@ "nice_response", "nice_duration") -populate_localized_function_dict("format", langs=get_active_langs()) - - def _translate_word(name, lang=''): """ Helper to get word translations @@ -566,3 +563,5 @@ def nice_response(text, lang=''): assertEqual(nice_response_de("10 ^ 2"), "10 hoch 2") """ + +populate_localized_function_dict("format", langs=get_active_langs()) diff --git a/lingua_franca/parse.py b/lingua_franca/parse.py index 698c42be..d13b4ada 100644 --- a/lingua_franca/parse.py +++ b/lingua_franca/parse.py @@ -30,9 +30,6 @@ "is_fractional", "is_ordinal") -populate_localized_function_dict("parse", langs=get_active_langs()) - - def fuzzy_match(x: str, against: str) -> float: """Perform a 'fuzzy' comparison between two strings. @@ -267,3 +264,5 @@ def is_ordinal(input_str, lang=''): (bool) or (float): False if not an ordinal, otherwise the number corresponding to the ordinal """ + +populate_localized_function_dict("parse", langs=get_active_langs()) diff --git a/setup.py b/setup.py index f9ced471..00d60ff2 100644 --- a/setup.py +++ b/setup.py @@ -27,7 +27,7 @@ def required(requirements_file): setup( name='lingua_franca', - version='0.4.2', + version='0.4.6', packages=['lingua_franca', 'lingua_franca.lang'], url='https://github.com/MycroftAI/lingua-franca', license='Apache2.0',